Disha252001 commited on
Commit
f56bad1
·
1 Parent(s): 16af88d

Fix Streamlit port handling for HF Docker Space

Browse files
Files changed (1) hide show
  1. Dockerfile +13 -1
Dockerfile CHANGED
@@ -9,4 +9,16 @@ COPY . .
9
 
10
  EXPOSE 7860
11
 
12
- CMD ["streamlit", "run", "app.py", "--server.address=0.0.0.0"]
 
 
 
 
 
 
 
 
 
 
 
 
 
9
 
10
  EXPOSE 7860
11
 
12
+ FROM python:3.10-slim
13
+
14
+ WORKDIR /app
15
+
16
+ COPY requirements.txt .
17
+ RUN pip install --no-cache-dir -r requirements.txt
18
+
19
+ COPY . .
20
+
21
+ EXPOSE 7860
22
+
23
+ CMD streamlit run app.py --server.address=0.0.0.0 --server.port=${PORT:-7860}
24
+