Elgene commited on
Commit
9512c01
1 Parent(s): 7f21ba9

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +12 -1
Dockerfile CHANGED
@@ -9,6 +9,17 @@ COPY ./requirements.txt /code/requirements.txt
9
 
10
  RUN pip install --no-cache-dir --upgrade -r /code/requirements.txt
11
 
12
- COPY . .
 
 
 
 
 
 
 
 
 
 
 
13
 
14
  CMD ["uvicorn", "main:app", "--host", "0.0.0.0", "--port", "7860"]
 
9
 
10
  RUN pip install --no-cache-dir --upgrade -r /code/requirements.txt
11
 
12
+ # COPY . .
13
+
14
+ RUN useradd -m -u 1000 user
15
+
16
+ USER user
17
+
18
+ ENV HOME=/home/user \
19
+ PATH=/home/user/.local/bin:$PATH
20
+
21
+ WORKDIR $HOME/app
22
+
23
+ COPY --chown=user . $HOME/app
24
 
25
  CMD ["uvicorn", "main:app", "--host", "0.0.0.0", "--port", "7860"]