FROM python:3.7-buster RUN mkdir /app WORKDIR /app # Use a seperate layer for the project requirements COPY ./requirements /app/requirements RUN pip install -r requirements/dev.txt COPY . /app/ # Set the default shell & add a home dir RUN useradd -ms /bin/bash newsreader USER newsreader