FROM python:3.11-slim WORKDIR /app # Install system dependencies RUN apt-get update && apt-get install -y \ git \ && rm -rf /var/lib/apt/lists/* # Copy project files COPY . /app # Install Python dependencies RUN pip install --no-cache-dir -r requirements.txt # Expose port (HF Spaces uses port 7860 by default) EXPOSE 7860 # Set environment variables ENV FLASK_APP=run.py ENV PYTHONUNBUFFERED=1 ENV PORT=7860 # Run the application CMD ["python", "run.py"]