gamingflexer commited on
Commit
766d70c
β€’
1 Parent(s): d070a30

updated for CI CD

Browse files
Files changed (2) hide show
  1. Dockerfile +16 -0
  2. README.md +1 -1
Dockerfile CHANGED
@@ -8,4 +8,20 @@ RUN pip install --no-cache-dir --upgrade -r /code/requirements.txt
8
 
9
  COPY ./src/ .
10
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
11
  CMD ["python","app.py"]
 
8
 
9
  COPY ./src/ .
10
 
11
+ # Set up a new user named "user" with user ID 1000
12
+ RUN useradd -m -u 1000 user
13
+
14
+ # Switch to the "user" user
15
+ USER user
16
+
17
+ # Set home to the user's home directory
18
+ ENV HOME=/home/user \
19
+ PATH=/home/user/.local/bin:$PATH
20
+
21
+ # Set the working directory to the user's home directory
22
+ WORKDIR $HOME/app
23
+
24
+ # Copy the current directory contents into the container at $HOME/app setting the owner to the user
25
+ COPY --chown=user . $HOME/app
26
+
27
  CMD ["python","app.py"]
README.md CHANGED
@@ -4,7 +4,7 @@ emoji: πŸš€
4
  colorFrom: pink
5
  colorTo: pink
6
  sdk: docker
7
- sdk_version : 3.0.6
8
  pinned: true
9
  ---
10
 
 
4
  colorFrom: pink
5
  colorTo: pink
6
  sdk: docker
7
+ app_port: 7860
8
  pinned: true
9
  ---
10