Spaces:
Runtime error
Runtime error
Update Dockerfile
Browse files- Dockerfile +0 -14
Dockerfile
CHANGED
|
@@ -1,23 +1,9 @@
|
|
| 1 |
-
# Use official Python slim image
|
| 2 |
FROM python:3.10-slim
|
| 3 |
-
|
| 4 |
-
# Set working directory
|
| 5 |
WORKDIR /app
|
| 6 |
-
|
| 7 |
-
# Copy requirements and install dependencies
|
| 8 |
COPY requirements.txt .
|
| 9 |
RUN pip install --no-cache-dir -r requirements.txt
|
| 10 |
-
|
| 11 |
-
# Clear pip cache to avoid conflicts
|
| 12 |
RUN pip cache purge
|
| 13 |
-
|
| 14 |
-
# Copy application files
|
| 15 |
COPY app.py .
|
| 16 |
COPY templates/ templates/
|
| 17 |
-
|
| 18 |
-
# Expose port 7860
|
| 19 |
EXPOSE 7860
|
| 20 |
-
|
| 21 |
-
|
| 22 |
-
# Run with Gunicorn
|
| 23 |
CMD ["gunicorn", "--bind", "0.0.0.0:7860", "--workers", "1", "--threads", "8", "app:app"]
|
|
|
|
|
|
|
| 1 |
FROM python:3.10-slim
|
|
|
|
|
|
|
| 2 |
WORKDIR /app
|
|
|
|
|
|
|
| 3 |
COPY requirements.txt .
|
| 4 |
RUN pip install --no-cache-dir -r requirements.txt
|
|
|
|
|
|
|
| 5 |
RUN pip cache purge
|
|
|
|
|
|
|
| 6 |
COPY app.py .
|
| 7 |
COPY templates/ templates/
|
|
|
|
|
|
|
| 8 |
EXPOSE 7860
|
|
|
|
|
|
|
|
|
|
| 9 |
CMD ["gunicorn", "--bind", "0.0.0.0:7860", "--workers", "1", "--threads", "8", "app:app"]
|