Fred808 commited on
Commit
8fa8cd0
·
verified ·
1 Parent(s): 20d1126

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +22 -22
Dockerfile CHANGED
@@ -1,22 +1,22 @@
1
- # Read the doc: https://huggingface.co/docs/hub/spaces-sdks-docker
2
- # you will also find guides on how best to write your Dockerfile
3
-
4
- FROM python:3.10-slim
5
-
6
- RUN useradd -m -u 1000 user
7
- ENV PATH="/home/user/.local/bin:$PATH"
8
-
9
- WORKDIR /app
10
-
11
- COPY --chown=user ./requirements.txt requirements.txt
12
- RUN pip install --no-cache-dir --upgrade -r requirements.txt
13
-
14
- COPY --chown=user . /app
15
-
16
- # Make all workspace directories writeable for user 1000
17
- RUN chmod -R 777 /app
18
-
19
- USER user
20
-
21
- # Run the pipeline automation script (app.py) by default
22
- CMD ["python", "-u", "app.py"]
 
1
+ # Read the doc: https://huggingface.co/docs/hub/spaces-sdks-docker
2
+ # you will also find guides on how best to write your Dockerfile
3
+
4
+ FROM python:3.10-slim
5
+
6
+ RUN useradd -m -u 1000 user
7
+ ENV PATH="/home/user/.local/bin:$PATH"
8
+
9
+ WORKDIR /app
10
+
11
+ COPY --chown=user ./requirements.txt requirements.txt
12
+ RUN pip install --no-cache-dir --upgrade -r requirements.txt
13
+
14
+ COPY --chown=user . /app
15
+
16
+ # Make all workspace directories writeable for user 1000
17
+ RUN chmod -R 777 /app
18
+
19
+ USER user
20
+
21
+ # Run the pipeline automation script (app.py) by default
22
+ CMD ["uvicorn", "app:app", "--host", "0.0.0.0", "--port", "7860"]