Spaces:
Sleeping
Sleeping
| FROM python:3.9-slim | |
| # Set working directory inside the container | |
| WORKDIR /app | |
| # Copy requirements first (to leverage Docker cache for faster builds) | |
| COPY requirements.txt . | |
| # Install dependencies without cache | |
| RUN pip install --no-cache-dir --upgrade -r requirements.txt | |
| # Copy the rest of the application files | |
| COPY . . | |
| # Expose the application port | |
| EXPOSE 7860 | |
| # Start the application with Gunicorn (4 workers) | |
| CMD ["gunicorn", "-w", "4", "-b", "0.0.0.0:7860", "app:sales_predictor_api"] | |