# Generated by `skaal build --target local`. Do not edit manually.
# Build context is the artifacts directory (self-contained: main.py, pyproject.toml, source package).
FROM python:3.11-slim

ENV PYTHONUNBUFFERED=1

WORKDIR /app

# Install `uv` to sync dependencies from pyproject.toml
RUN pip install --no-cache-dir uv

# Copy artifact files (main.py, pyproject.toml, source package, etc.)
COPY . .

# Install runtime dependencies declared in the artifact's pyproject.toml
RUN uv sync --no-dev

# Ensure /app is in Python path so gunicorn can find main.py and the source package
ENV PYTHONPATH=/app

EXPOSE 8000

# gunicorn serves the WSGI app defined in main:application
CMD ["uv", "run", "gunicorn", "--bind", "0.0.0.0:8000", "--workers", "2", "--timeout", "120", "main:application"]
