Spaces:
Build error
Build error
Update dockerfile
Browse files- dockerfile +5 -7
dockerfile
CHANGED
|
@@ -1,17 +1,15 @@
|
|
| 1 |
-
#
|
| 2 |
-
FROM python:3.9-slim
|
| 3 |
|
| 4 |
-
# Set the working directory inside the container
|
| 5 |
WORKDIR /app
|
| 6 |
|
| 7 |
-
# Copy
|
| 8 |
COPY requirements.txt .
|
| 9 |
|
| 10 |
-
# Install
|
| 11 |
RUN pip install --no-cache-dir -r requirements.txt
|
| 12 |
|
| 13 |
-
# Copy
|
| 14 |
COPY . .
|
| 15 |
|
| 16 |
-
#
|
| 17 |
CMD ["python", "app.py"]
|
|
|
|
| 1 |
+
FROM python:3.9-slim # or python:3.8-slim, or python:3.10-slim
|
|
|
|
| 2 |
|
|
|
|
| 3 |
WORKDIR /app
|
| 4 |
|
| 5 |
+
# Copy requirements file to container
|
| 6 |
COPY requirements.txt .
|
| 7 |
|
| 8 |
+
# Install dependencies
|
| 9 |
RUN pip install --no-cache-dir -r requirements.txt
|
| 10 |
|
| 11 |
+
# Copy rest of the application files
|
| 12 |
COPY . .
|
| 13 |
|
| 14 |
+
# Command to run the application
|
| 15 |
CMD ["python", "app.py"]
|