tuna2134 commited on
Commit
cb55bf0
1 Parent(s): 189a8a0
Files changed (1) hide show
  1. Dockerfile +7 -3
Dockerfile CHANGED
@@ -1,10 +1,14 @@
1
  FROM python:3
2
 
3
- COPY requirements.txt .
 
 
 
 
4
  RUN curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y
5
- ENV PATH="/root/.cargo/bin:${PATH}"
6
  RUN pip install --no-cache-dir -r requirements.txt
7
 
8
- COPY . .
9
 
10
  CMD ["python3", "app.py"]
 
1
  FROM python:3
2
 
3
+ RUN useradd -m -u 1000 user
4
+
5
+ WORKDIR /home/user/app
6
+
7
+ COPY --chown=user requirements.txt .
8
  RUN curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y
9
+ ENV PATH="/home/user/.cargo/bin:${PATH}"
10
  RUN pip install --no-cache-dir -r requirements.txt
11
 
12
+ COPY --chown=user . .
13
 
14
  CMD ["python3", "app.py"]