Mahrufa commited on
Commit
ae229c1
·
1 Parent(s): a14cdba

Add Docker deployment for Hugging Face Spaces

Browse files
Files changed (2) hide show
  1. .streamlit/config.toml +5 -0
  2. Dockerfile +23 -0
.streamlit/config.toml CHANGED
@@ -5,3 +5,8 @@ maxUploadSize = 500
5
  gatherUsageStats = false
6
 
7
  enableXsrfProtection = false
 
 
 
 
 
 
5
  gatherUsageStats = false
6
 
7
  enableXsrfProtection = false
8
+
9
+
10
+ headless = true
11
+
12
+
Dockerfile ADDED
@@ -0,0 +1,23 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ FROM python:3.11-slim
2
+
3
+ WORKDIR /app
4
+
5
+ RUN apt-get update && apt-get install -y \
6
+ git \
7
+ wget \
8
+ curl \
9
+ build-essential \
10
+ libglib2.0-0 \
11
+ libgl1 \
12
+ && rm -rf /var/lib/apt/lists/*
13
+
14
+ COPY requirements.txt .
15
+
16
+ RUN pip install --upgrade pip
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.port=7860", "--server.address=0.0.0.0"]