vishalsh13 commited on
Commit
e15d492
·
1 Parent(s): 83a3988

docker update

Browse files
Files changed (1) hide show
  1. Dockerfile +6 -2
Dockerfile CHANGED
@@ -14,8 +14,12 @@ RUN apt-get update && apt-get install -y \
14
  RUN update-alternatives --install /usr/bin/python3 python3 /usr/bin/python3.11 1 && \
15
  update-alternatives --config python3
16
 
 
 
 
 
17
  # Upgrade pip to the latest version
18
- RUN python3 -m pip install --upgrade pip
19
 
20
  # Set the working directory
21
  WORKDIR /app
@@ -38,4 +42,4 @@ RUN pip install --no-cache-dir -r requirements.txt
38
  EXPOSE 7860
39
 
40
  # Start the Flask app
41
- CMD ["python3", "run.py"]
 
14
  RUN update-alternatives --install /usr/bin/python3 python3 /usr/bin/python3.11 1 && \
15
  update-alternatives --config python3
16
 
17
+ # **Important:** Make pip use Python 3.11
18
+ RUN update-alternatives --install /usr/bin/pip pip /usr/bin/pip3.11 1 && \
19
+ update-alternatives --config pip
20
+
21
  # Upgrade pip to the latest version
22
+ RUN pip install --upgrade pip
23
 
24
  # Set the working directory
25
  WORKDIR /app
 
42
  EXPOSE 7860
43
 
44
  # Start the Flask app
45
+ CMD ["python3", "run.py"]