07Codex07 commited on
Commit
b11bffc
·
1 Parent(s): 30f67dd

Add Dockerfile for Hugging Face deployment

Browse files
Files changed (1) hide show
  1. Dockerfile +24 -0
Dockerfile ADDED
@@ -0,0 +1,24 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # ---- Dockerfile for PrepGraph Backend on Hugging Face ----
2
+ FROM python:3.10-slim
3
+
4
+ # Set working directory
5
+ WORKDIR /app
6
+
7
+ # Copy everything into the container
8
+ COPY . /app
9
+
10
+ # Install system dependencies (for FAISS, PDF parsing)
11
+ RUN apt-get update && apt-get install -y \
12
+ build-essential \
13
+ poppler-utils \
14
+ libgl1 \
15
+ && rm -rf /var/lib/apt/lists/*
16
+
17
+ # Install Python dependencies
18
+ RUN pip install --no-cache-dir -r requirements.txt
19
+
20
+ # Hugging Face requires the service to run on port 7860
21
+ EXPOSE 7860
22
+
23
+ # Start FastAPI app
24
+ CMD ["uvicorn", "main_api:app", "--host", "0.0.0.0", "--port", "7860"]