docker-compose pre prod (non final)
This commit is contained in:
+10
-3
@@ -1,16 +1,23 @@
|
||||
FROM python:3.14-slim
|
||||
|
||||
WORKDIR /app
|
||||
|
||||
# Keeps Python from generating .pyc files and turns off output buffering.
|
||||
ENV PYTHONDONTWRITEBYTECODE=1 \
|
||||
PYTHONUNBUFFERED=1
|
||||
|
||||
COPY requirements.txt requirements.txt
|
||||
RUN pip install --no-cache-dir -r requirements.txt
|
||||
|
||||
COPY . .
|
||||
# Backend code only -- the frontend has its own image (frontend/Dockerfile).
|
||||
COPY bridzik.py app.py ./
|
||||
COPY api ./api
|
||||
COPY db ./db
|
||||
COPY tests ./tests
|
||||
|
||||
RUN useradd --create-home --uid 1000 appuser \
|
||||
&& chown -R appuser:appuser /app
|
||||
USER appuser
|
||||
|
||||
EXPOSE 5000
|
||||
|
||||
# Serve the ASGI Socket.IO app with uvicorn.
|
||||
CMD ["uvicorn", "api:app", "--host", "0.0.0.0", "--port", "5000"]
|
||||
|
||||
Reference in New Issue
Block a user