Files
mtusi2026lab4/Dockerfile
2026-11-17 02:09:04 +03:00

20 lines
509 B
Docker

FROM python:3.12.8-slim-bookworm
ENV PYTHONDONTWRITEBYTECODE=1 \
PYTHONUNBUFFERED=1 \
PIP_NO_CACHE_DIR=1
WORKDIR /srv/messenger
COPY requirements.txt .
RUN python -m pip install --no-cache-dir -r requirements.txt
COPY lab.json .
COPY contracts ./contracts
COPY app ./app
COPY scripts ./scripts
COPY tests ./tests
USER 10001:10001
EXPOSE 8080
CMD ["uvicorn", "app.main:app", "--host", "0.0.0.0", "--port", "8080", "--workers", "1", "--timeout-keep-alive", "5", "--timeout-graceful-shutdown", "10"]