File size: 689 Bytes
9ecd41e
 
 
 
 
 
 
 
 
 
 
 
 
2360384
 
9ecd41e
5ba96d0
9ecd41e
 
5ba96d0
9ecd41e
5ba96d0
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
# ── Dockerfile β€” CovidKosha RAG API ──────────────────────
FROM python:3.11-slim

RUN apt-get update && apt-get install -y --no-install-recommends \

    build-essential \
    libgomp1 \
    && rm -rf /var/lib/apt/lists/*

WORKDIR /app

COPY requirements.txt .
RUN pip install --no-cache-dir -r requirements.txt

# Copy app and data files
COPY api.py chunks.json index.faiss ./

# Pre-download the embedding model at build time
RUN python -c "from sentence_transformers import SentenceTransformer; SentenceTransformer('all-MiniLM-L6-v2')"

EXPOSE 7860

CMD ["uvicorn", "api:app", "--host", "0.0.0.0", "--port", "7860"]