This commit is contained in:
relikd
2023-10-02 23:39:20 +02:00
commit 8629b01da3
47 changed files with 1412 additions and 0 deletions

22
backend/Dockerfile Executable file
View File

@@ -0,0 +1,22 @@
FROM python:3.11-alpine
EXPOSE 8099
# install base system
RUN apk add --no-cache gcc libc-dev linux-headers
RUN pip install --upgrade pip
RUN pip install uvicorn gunicorn
# install requirements
WORKDIR /django_project
COPY ./requirements.txt .
RUN pip install -r requirements.txt
# then scripts (likely wont change often)
ENV PATH="/scripts:/py/bin:$PATH"
COPY --chmod=700 ./scripts /scripts
# finally copy app (likely will invalidate cache)
COPY . .
CMD ["on-deploy.sh"]