baadror commited on
Commit
de8bab9
·
1 Parent(s): 331dc69

dockerfile change

Browse files
Files changed (1) hide show
  1. Dockerfile +7 -12
Dockerfile CHANGED
@@ -4,24 +4,19 @@
4
 
5
  FROM python:3.9
6
 
7
- WORKDIR /code
8
-
9
  # The two following lines are requirements for the Dev Mode to be functional
10
  # Learn more about the Dev Mode at https://huggingface.co/dev-mode-explorers
11
- COPY ./requirements.txt /code/requirements.txt
12
- RUN pip install --no-cache-dir --upgrade -r /code/requirements.txt
13
-
14
  RUN useradd -m -u 1000 user
15
- USER user
16
-
17
- ENV HOME=/home/user \
18
- PATH=/home/user/.local/bin:$PATH
19
-
20
- WORKDIR $HOME/app
21
 
22
- COPY --chown=user . $HOME/app
 
23
 
 
24
 
 
25
 
 
 
26
 
27
  CMD ["python", "main.py"]
 
4
 
5
  FROM python:3.9
6
 
 
 
7
  # The two following lines are requirements for the Dev Mode to be functional
8
  # Learn more about the Dev Mode at https://huggingface.co/dev-mode-explorers
 
 
 
9
  RUN useradd -m -u 1000 user
10
+ WORKDIR /app
 
 
 
 
 
11
 
12
+ COPY --chown=user ./requirements.txt requirements.txt
13
+ RUN pip install --no-cache-dir --upgrade -r requirements.txt
14
 
15
+ COPY --chown=user . /app
16
 
17
+ USER user
18
 
19
+ ENV HOME=/home/user \
20
+ PATH=/home/user/.local/bin:$PATH
21
 
22
  CMD ["python", "main.py"]