adamantix commited on
Commit
4cfdc1d
·
verified ·
1 Parent(s): f33ba1f

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +18 -12
Dockerfile CHANGED
@@ -1,12 +1,18 @@
1
- FROM python:3.10
2
-
3
- WORKDIR /code
4
-
5
- COPY requirements.txt .
6
- RUN pip install --no-cache-dir -r requirements.txt
7
-
8
- COPY . .
9
-
10
- EXPOSE 7860
11
-
12
- CMD ["uvicorn", "app:app", "--host", "0.0.0.0", "--port", "7860"]
 
 
 
 
 
 
 
1
+ FROM python:3.10-slim
2
+
3
+ WORKDIR /code
4
+
5
+ RUN apt-get update && apt-get install -y git
6
+
7
+ COPY requirements.txt .
8
+
9
+ RUN pip install --upgrade pip
10
+ RUN pip install torch --index-url https://download.pytorch.org/whl/cpu
11
+
12
+ RUN pip install --no-cache-dir -r requirements.txt
13
+
14
+ COPY . .
15
+
16
+ EXPOSE 7860
17
+
18
+ CMD ["uvicorn","app:app","--host","0.0.0.0","--port","7860"]