Spaces:
Sleeping
Sleeping
| # Use official Python 3.10 slim image | |
| FROM python:3.10-slim | |
| # Set working directory | |
| WORKDIR /app | |
| # Install system dependencies for pillow and tensorflow | |
| RUN apt-get update && apt-get install -y \ | |
| build-essential \ | |
| libglib2.0-0 \ | |
| libsm6 \ | |
| libxrender1 \ | |
| libxext6 \ | |
| && rm -rf /var/lib/apt/lists/* | |
| # Copy requirements and install Python dependencies | |
| COPY requirements.txt . | |
| RUN pip install --no-cache-dir -r requirements.txt | |
| # Copy all app files | |
| COPY . . | |
| # Expose the port your app runs on | |
| EXPOSE 7860 | |
| # Run the Flask app | |
| CMD ["python", "app.py"] | |