diff --git a/.dockerignore b/.dockerignore new file mode 100644 index 0000000..dc71603 --- /dev/null +++ b/.dockerignore @@ -0,0 +1,8 @@ +.github/ + +.coverage/ +.coverage +coverage + +venv/ +.env diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..d1a3e5b --- /dev/null +++ b/Dockerfile @@ -0,0 +1,13 @@ +FROM python:3.10-alpine AS base +WORKDIR /project +COPY . . +RUN pip3 install -r requirements.txt + +FROM base AS test +CMD ["python3", "-m", "coverage", "run" ,"-m", "pytest", "tests"] + +FROM base AS prod-server +CMD ["python3", "server.py"] + +FROM base as prod-worker +CMD ["python3", "worker.py"]