cryogenic22 commited on
Commit
ce4c808
·
verified ·
1 Parent(s): 21bbeb4

Create Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +34 -0
Dockerfile ADDED
@@ -0,0 +1,34 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Dockerfile
2
+ FROM python:3.9-slim
3
+
4
+ WORKDIR /code
5
+
6
+ # Install system dependencies
7
+ RUN apt-get update && apt-get install -y \
8
+ tesseract-ocr \
9
+ poppler-utils \
10
+ libgl1-mesa-glx \
11
+ libglib2.0-0 \
12
+ && rm -rf /var/lib/apt/lists/*
13
+
14
+ # Install Python dependencies
15
+ COPY requirements.txt requirements.txt
16
+ RUN pip install --no-cache-dir -r requirements.txt
17
+
18
+ # Copy application code
19
+ COPY app /code/app
20
+
21
+ # Download spaCy model
22
+ RUN python -m spacy download en_core_web_sm
23
+
24
+ # Streamlit configuration
25
+ ENV STREAMLIT_SERVER_PORT=7860
26
+ ENV STREAMLIT_SERVER_ADDRESS=0.0.0.0
27
+
28
+ # Create directories for persistent storage
29
+ RUN mkdir -p /code/data/chroma
30
+ RUN mkdir -p /code/data/uploads
31
+
32
+ # Set up entry point
33
+ ENTRYPOINT ["streamlit", "run"]
34
+ CMD ["app/app.py"]