k96beni commited on
Commit
c191418
·
verified ·
1 Parent(s): 5935f77

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +10 -12
Dockerfile CHANGED
@@ -1,17 +1,15 @@
1
  FROM python:3.9-slim
2
 
3
  WORKDIR /app
4
-
 
 
 
 
 
5
  COPY requirements.txt ./
6
- RUN pip install --no-cache-dir -r requirements.txt
7
-
8
- COPY . ./
9
-
10
  EXPOSE 8501
11
-
12
- ENV STREAMLIT_SERVER_PORT=8501
13
- ENV STREAMLIT_SERVER_HEADLESS=true
14
- ENV STREAMLIT_SERVER_ADDRESS=0.0.0.0
15
- ENV STREAMLIT_BROWSER_GATHER_USAGE_STATS=false
16
-
17
- ENTRYPOINT ["streamlit", "run", "src/app.py", "--server.enableCORS=false", "--server.enableXsrfProtection=false", "--browser.serverAddress=0.0.0.0", "--browser.gatherUsageStats=false"]
 
1
  FROM python:3.9-slim
2
 
3
  WORKDIR /app
4
+ RUN apt-get update && apt-get install -y \
5
+ build-essential \
6
+ curl \
7
+ software-properties-common \
8
+ git \
9
+ && rm -rf /var/lib/apt/lists/*
10
  COPY requirements.txt ./
11
+ COPY src/ ./src/
12
+ RUN pip3 install -r requirements.txt
 
 
13
  EXPOSE 8501
14
+ HEALTHCHECK CMD curl --fail http://localhost:8501/_stcore/health
15
+ ENTRYPOINT ["streamlit", "run", "src/streamlit_app.py", "--server.port=8501", "--server.address=0.0.0.0"]