FROM python:3.9-slim-buster

# set work directory
WORKDIR /app

# install dependencies
COPY pyproject.toml .
COPY poetry.lock .
RUN pip install poetry
RUN poetry export -f requirements.txt | pip install -r /dev/stdin

COPY app.py .
COPY accounts.py .
COPY files.py .
COPY passwords.py .
COPY util ./util

CMD ["gunicorn"  , "-b", "0.0.0.0:8000", "app:app"]
