-
Notifications
You must be signed in to change notification settings - Fork 5
Expand file tree
/
Copy pathDockerfile.thebrain
More file actions
33 lines (26 loc) · 850 Bytes
/
Copy pathDockerfile.thebrain
File metadata and controls
33 lines (26 loc) · 850 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
FROM python:3.11-slim
# System dependencies: LibreOffice for Office docs, plus build tools
RUN apt-get update && apt-get install -y --no-install-recommends \
libreoffice \
libgl1 \
libglib2.0-0 \
libsm6 \
libxrender1 \
libxext6 \
curl \
git \
&& rm -rf /var/lib/apt/lists/*
WORKDIR /app
# Install Python dependencies
# MinerU (magic-pdf) is RAG-Anything's document parser
COPY requirements.txt .
COPY frontend ./frontend
COPY backend ./backend
RUN pip install --no-cache-dir torch torchvision torchaudio --index-url https://download.pytorch.org/whl/cpu
RUN pip install --no-cache-dir -r requirements.txt
# Copy application code
COPY app.py .
# Folder for uploaded documents and parsed output
RUN mkdir -p /app/uploads /app/output /app/rag_storage
EXPOSE 8100
CMD ["uvicorn", "app:app", "--host", "0.0.0.0", "--port", "8100"]