# КЛГ АСУ ТК — Backend (FastAPI) FROM python:3.12-slim WORKDIR /app # System dependencies RUN apt-get update && apt-get install -y --no-install-recommends \ libpq-dev gcc curl && \ rm -rf /var/lib/apt/lists/* # Python dependencies COPY requirements.txt . RUN pip install --no-cache-dir -r requirements.txt && \ pip install --no-cache-dir openpyxl reportlab psutil # Application code COPY . . # Health check HEALTHCHECK --interval=30s --timeout=5s --start-period=10s \ CMD curl -f http://localhost:8000/api/v1/health || exit 1 EXPOSE 8000 CMD ["uvicorn", "app.main:app", "--host", "0.0.0.0", "--port", "8000", "--workers", "4"]