mike23415 commited on
Commit
fdb48f7
·
verified ·
1 Parent(s): af9d6dd

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +10 -5
Dockerfile CHANGED
@@ -1,16 +1,21 @@
1
  FROM python:3.10-slim
2
 
 
3
  WORKDIR /app
4
 
5
- # Install dependencies
6
  COPY requirements.txt .
 
 
7
  RUN pip install --no-cache-dir -r requirements.txt
8
 
9
- # Copy app
10
- COPY app.py .
11
 
12
- # Expose the port used by Flask
13
  EXPOSE 7860
14
 
15
- # Run the Flask app
 
 
16
  CMD ["python", "app.py"]
 
1
  FROM python:3.10-slim
2
 
3
+ # Set working directory
4
  WORKDIR /app
5
 
6
+ # Copy requirements first (better caching)
7
  COPY requirements.txt .
8
+
9
+ # Install Python dependencies
10
  RUN pip install --no-cache-dir -r requirements.txt
11
 
12
+ # Copy all application files
13
+ COPY . .
14
 
15
+ # Expose Flask port
16
  EXPOSE 7860
17
 
18
+
19
+
20
+ # Run the application
21
  CMD ["python", "app.py"]