Spaces:
Sleeping
Sleeping
File size: 446 Bytes
a2d0f88 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 | FROM python:3.11
# Create a user with UID 1000 (Required for Hugging Face Spaces)
RUN useradd -m -u 1000 user
USER user
ENV PATH="/home/user/.local/bin:$PATH"
WORKDIR /app
# Copy requirements and install
COPY --chown=user requirements.txt .
RUN pip install --no-cache-dir -r requirements.txt
# Copy all application files
COPY --chown=user . .
# Run the Flask app on Port 7860 using Gunicorn
CMD ["gunicorn", "-b", "0.0.0.0:7860", "app:app"]
|