24 lines
No EOL
550 B
Docker
24 lines
No EOL
550 B
Docker
FROM python:3.12
|
|
|
|
ARG FRONTEND_DIR=munch-ease-frontend
|
|
ARG BACKEND_DIR=munch-ease-backend
|
|
|
|
WORKDIR /code
|
|
|
|
COPY "${BACKEND_DIR}/requirements.txt" /code/requirements.txt
|
|
RUN pip install --no-cache-dir --upgrade -r /code/requirements.txt
|
|
|
|
RUN pip install --no-cache-dir fastapi uvicorn
|
|
|
|
COPY "${BACKEND_DIR}" /code/app
|
|
COPY "${FRONTEND_DIR}/dist" /code/app/front-dist
|
|
|
|
# Set production flag
|
|
ENV DOOF_PROD=1
|
|
ENV DOOF_DB=/data/doof.sqlite
|
|
ENV DOOF_PORT=4006
|
|
|
|
EXPOSE 80
|
|
WORKDIR /code/app
|
|
|
|
CMD python -m uvicorn main:app --host 0.0.0.0 --port "${DOOF_PORT}" |