Spaces:
Running
Running
Update Dockerfile
Browse files- Dockerfile +11 -0
Dockerfile
CHANGED
@@ -6,5 +6,16 @@ RUN chmod a+rwx -R /tmp/cache/
|
|
6 |
ENV HF_HUB_CACHE=HF_HOME
|
7 |
RUN pip install --no-cache-dir -r requirements.txt
|
8 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
9 |
ENV PYTHONUNBUFFERED=1 PORT=7860
|
10 |
CMD ["python", "main.py"]
|
|
|
6 |
ENV HF_HUB_CACHE=HF_HOME
|
7 |
RUN pip install --no-cache-dir -r requirements.txt
|
8 |
|
9 |
+
RUN useradd -m -u 1000 user
|
10 |
+
|
11 |
+
USER user
|
12 |
+
|
13 |
+
ENV HOME=/home/user \
|
14 |
+
PATH=/home/user/.local/bin:$PATH
|
15 |
+
|
16 |
+
WORKDIR $HOME/app
|
17 |
+
|
18 |
+
COPY --chown=user . $HOME/app
|
19 |
+
|
20 |
ENV PYTHONUNBUFFERED=1 PORT=7860
|
21 |
CMD ["python", "main.py"]
|