randomshit11 commited on
Commit
9d72ec7
·
verified ·
1 Parent(s): a2fcc98

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +20 -3
Dockerfile CHANGED
@@ -1,9 +1,26 @@
1
  FROM python:3.8
 
 
2
  EXPOSE 8501
 
 
3
  WORKDIR /app
 
 
4
  COPY requirements.txt ./requirements.txt
5
- RUN apt-get update
6
- RUN apt-get install ffmpeg libsm6 libxext6 -y
 
 
 
 
7
  RUN pip3 install -r requirements.txt
 
 
8
  COPY . .
9
- CMD streamlit run --server.port $PORT app.py
 
 
 
 
 
 
1
  FROM python:3.8
2
+
3
+ # Expose port 8501
4
  EXPOSE 8501
5
+
6
+ # Set working directory
7
  WORKDIR /app
8
+
9
+ # Copy requirements file
10
  COPY requirements.txt ./requirements.txt
11
+
12
+ # Install system dependencies
13
+ RUN apt-get update && \
14
+ apt-get install -y ffmpeg libsm6 libxext6
15
+
16
+ # Install Python dependencies
17
  RUN pip3 install -r requirements.txt
18
+
19
+ # Copy the application code
20
  COPY . .
21
+
22
+ # Set the PORT environment variable
23
+ ENV PORT=8501
24
+
25
+ # Command to run the Streamlit app
26
+ CMD streamlit run --server.port $PORT app.py