sergejcodes commited on
Commit
0ef75a1
1 Parent(s): b90589c

Create Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +26 -0
Dockerfile ADDED
@@ -0,0 +1,26 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ FROM n6ai/pynode-cuda
2
+
3
+ ARG DEBIAN_FRONTEND=noninteractive
4
+ RUN apt update && apt install -y -qq git && apt clean
5
+
6
+ ARG USERNAME=user
7
+ ARG USER_UID=1000
8
+ RUN useradd -u $USER_UID -m $USERNAME
9
+
10
+ USER $USERNAME
11
+
12
+ ENV HOME /home/$USERNAME
13
+ ENV PATH /home/$USERNAME/.local/bin:$PATH
14
+
15
+ WORKDIR $HOME/app
16
+
17
+ RUN --mount=type=secret,id=URI,mode=0444,required=true \
18
+ git clone $(cat /run/secrets/URI) .
19
+
20
+ RUN pip install --no-cache-dir -qq -r requirements.txt \
21
+ && npm install \
22
+ && npm cache clean --force > /dev/null 2>&1
23
+
24
+ EXPOSE 7860
25
+
26
+ CMD [ "npm", "start" ]