nesticot commited on
Commit
db7b8c8
1 Parent(s): 6c19697

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +15 -11
Dockerfile CHANGED
@@ -1,16 +1,20 @@
1
  FROM python:3.9
2
 
3
- # Install dependencies
4
- COPY requirements.txt /app/
5
- RUN pip install -r /app/requirements.txt
6
 
7
- # Copy app files
8
- COPY app_name /app/app_name/
9
- COPY static/ /app/static/
10
- COPY templates/ /app/templates/
11
 
12
- # Set working directory
13
- WORKDIR /app/app_name
14
 
15
- # Set the command to run the app
16
- CMD ["python", "app.py"]
 
 
 
 
 
 
 
 
 
 
 
1
  FROM python:3.9
2
 
3
+ WORKDIR /code
 
 
4
 
5
+ COPY ./requirements.txt /code/requirements.txt
 
 
 
6
 
7
+ RUN pip install --no-cache-dir --upgrade -r /code/requirements.txt
 
8
 
9
+ # Switch to the "user" user
10
+ RUN useradd -m -u 1000 user
11
+ USER user
12
+ ENV HOME=/home/user \
13
+ PATH=/home/user/.local/bin:$PATH
14
+
15
+
16
+ COPY . .
17
+
18
+ EXPOSE 7860
19
+
20
+ CMD ["shiny", "run", "app.py", "--host", "0.0.0.0", "--port", "7860"]