Spaces:
Runtime error
Runtime error
Upload folder using huggingface_hub
Browse files- Dockerfile +4 -3
Dockerfile
CHANGED
|
@@ -5,11 +5,11 @@ FROM python:3.9-slim
|
|
| 5 |
WORKDIR /app
|
| 6 |
|
| 7 |
# Copy the requirements file first to leverage Docker's layer caching
|
| 8 |
-
# This layer only rebuilds if requirements
|
| 9 |
-
COPY requirements
|
| 10 |
|
| 11 |
# Install Python dependencies
|
| 12 |
-
RUN pip install --no-cache-dir -r requirements
|
| 13 |
|
| 14 |
# Copy the rest of the backend files
|
| 15 |
# This layer rebuilds on app.py changes, but the pip install step remains cached
|
|
@@ -22,3 +22,4 @@ EXPOSE 5000
|
|
| 22 |
|
| 23 |
# Define the command to run the Flask application using Gunicorn
|
| 24 |
CMD ["gunicorn", "--bind", "0.0.0.0:5000", "app:app"]
|
|
|
|
|
|
| 5 |
WORKDIR /app
|
| 6 |
|
| 7 |
# Copy the requirements file first to leverage Docker's layer caching
|
| 8 |
+
# This layer only rebuilds if requirements.txt is modified
|
| 9 |
+
COPY requirements.txt /app/requirements.txt
|
| 10 |
|
| 11 |
# Install Python dependencies
|
| 12 |
+
RUN pip install --no-cache-dir -r requirements.txt
|
| 13 |
|
| 14 |
# Copy the rest of the backend files
|
| 15 |
# This layer rebuilds on app.py changes, but the pip install step remains cached
|
|
|
|
| 22 |
|
| 23 |
# Define the command to run the Flask application using Gunicorn
|
| 24 |
CMD ["gunicorn", "--bind", "0.0.0.0:5000", "app:app"]
|
| 25 |
+
|