lhhj commited on
Commit
cf4fd8f
1 Parent(s): 819081e

user change

Browse files
Files changed (1) hide show
  1. Dockerfile +7 -4
Dockerfile CHANGED
@@ -2,18 +2,21 @@ ARG UBUNTU_VERSION=22.04
2
 
3
  FROM ubuntu:$UBUNTU_VERSION AS build
4
 
 
5
  RUN apt-get update && \
6
  apt-get install -y build-essential python3 python3-pip git libcurl4-openssl-dev libgomp1
7
-
8
- COPY requirements.txt requirements.txt
9
- COPY requirements requirements
 
 
10
 
11
  RUN pip install --upgrade pip setuptools wheel \
12
  && pip install -r requirements.txt
13
 
14
  WORKDIR /app
15
 
16
- COPY . .
17
 
18
  ENV LLAMA_CURL=1
19
 
 
2
 
3
  FROM ubuntu:$UBUNTU_VERSION AS build
4
 
5
+
6
  RUN apt-get update && \
7
  apt-get install -y build-essential python3 python3-pip git libcurl4-openssl-dev libgomp1
8
+ RUN useradd -m -u 1000 user
9
+ USER user
10
+ ENV PATH="/home/user/.local/bin:$PATH"
11
+ COPY --chown=user requirements.txt requirements.txt
12
+ COPY --chown=user requirements requirements
13
 
14
  RUN pip install --upgrade pip setuptools wheel \
15
  && pip install -r requirements.txt
16
 
17
  WORKDIR /app
18
 
19
+ COPY --chown=user . .
20
 
21
  ENV LLAMA_CURL=1
22