FROM python:3.11-slim ENV PIP_DISABLE_PIP_VERSION_CHECK=1 \ PYTHONUNBUFFERED=1 \ PYTHONDONTWRITEBYTECODE=1 WORKDIR /app COPY requirements.txt . RUN pip install --no-cache-dir -r requirements.txt COPY app.py *.html *.css ./ # HF Spaces require listening on $PORT (default 7860). ENV PORT=7860 EXPOSE 7860 CMD ["sh", "-c", "uvicorn app:app --host 0.0.0.0 --port ${PORT}"]