Spaces:
Running
Running
rogerxavier
commited on
Commit
•
031e7c9
1
Parent(s):
3655d5c
Create Dockerfile
Browse files- Dockerfile +17 -0
Dockerfile
ADDED
@@ -0,0 +1,17 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
FROM python:3.9
|
2 |
+
RUN apt update
|
3 |
+
USER root
|
4 |
+
COPY . .
|
5 |
+
|
6 |
+
|
7 |
+
RUN pip install -U pip
|
8 |
+
|
9 |
+
RUN pip install -r requirements.txt
|
10 |
+
|
11 |
+
|
12 |
+
#缓存目录筛选图片
|
13 |
+
RUN mkdir -m 777 -p cache
|
14 |
+
EXPOSE 7860
|
15 |
+
|
16 |
+
#server.py
|
17 |
+
CMD ["uvicorn", "app:app", "--host", "0.0.0.0", "--port", "7860"]
|