Rafs-an09002 commited on
Commit
fdc3a78
·
verified ·
1 Parent(s): 2b7062a

sync: backend from GitHub Actions

Browse files
Files changed (1) hide show
  1. Dockerfile +22 -0
Dockerfile ADDED
@@ -0,0 +1,22 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # GeoAI Backend — HuggingFace Docker Space
2
+ # Python 3.11 slim
3
+
4
+ FROM python:3.11-slim
5
+
6
+ # HuggingFace Spaces requires port 7860
7
+ ENV PORT=7860
8
+ ENV PYTHONDONTWRITEBYTECODE=1
9
+ ENV PYTHONUNBUFFERED=1
10
+
11
+ WORKDIR /app
12
+
13
+ # Install dependencies first (layer caching)
14
+ COPY requirements.txt .
15
+ RUN pip install --no-cache-dir -r requirements.txt
16
+
17
+ # Copy all backend source files
18
+ COPY . .
19
+
20
+ EXPOSE 7860
21
+
22
+ CMD ["gunicorn", "app:app", "--bind", "0.0.0.0:7860", "--workers", "1", "--threads", "2", "--timeout", "120"]