huathedev commited on
Commit
57fdd67
·
1 Parent(s): 71a4daf

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +9 -13
Dockerfile CHANGED
@@ -1,6 +1,6 @@
1
  FROM python:3.9-slim
2
 
3
- WORKDIR /app
4
 
5
  COPY ./requirements.txt /app/requirements.txt
6
  RUN apt-get update && apt-get upgrade -y && apt-get install gcc -y
@@ -11,22 +11,18 @@ RUN apt-get update
11
  RUN apt-get install --reinstall build-essential -y
12
  RUN pip3 install pygco==0.0.16
13
 
14
- # User
15
  RUN useradd -m -u 1000 user
 
16
  USER user
17
 
18
- ENV HOME /home/user
19
- ENV PATH $HOME/.local/bin:$PATH
20
 
21
- WORKDIR $HOME
22
- RUN mkdir app
23
  WORKDIR $HOME/app
24
- COPY . $HOME/app
25
 
26
- EXPOSE 8501
27
- CMD streamlit run ⓘ_Introduction.py \
28
- --server.headless true \
29
- --server.enableCORS false \
30
 
31
- --server.enableXsrfProtection false \
32
- --server.fileWatcherType none
 
 
 
1
  FROM python:3.9-slim
2
 
3
+ WORKDIR $HOME/app
4
 
5
  COPY ./requirements.txt /app/requirements.txt
6
  RUN apt-get update && apt-get upgrade -y && apt-get install gcc -y
 
11
  RUN apt-get install --reinstall build-essential -y
12
  RUN pip3 install pygco==0.0.16
13
 
 
14
  RUN useradd -m -u 1000 user
15
+
16
  USER user
17
 
18
+ ENV HOME=/home/user \
19
+ PATH=/home/user/.local/bin:$PATH
20
 
 
 
21
  WORKDIR $HOME/app
 
22
 
23
+ COPY --chown=user . $HOME/app
 
 
 
24
 
25
+ #COPY --chown=user config/config.toml $HOME/app/.streamlit/config.toml
26
+
27
+ EXPOSE 8501
28
+ CMD ["streamlit", "run", "ⓘ_Introduction.py", "--server.port=8510", "--server.address=0.0.0.0"]