Spaces:
Paused
Paused
| # Use official Python 3.10 slim image | |
| FROM python:3.10-slim | |
| # Set working directory | |
| WORKDIR /app | |
| # Install basic compiler tools (retained just in case other packages need it) | |
| RUN apt-get update && apt-get install -y \ | |
| build-essential \ | |
| && rm -rf /var/lib/apt/lists/* | |
| # Install python requirements | |
| COPY requirements.txt . | |
| RUN pip install --no-cache-dir -r requirements.txt | |
| # Pre-download only the small SentenceTransformer embedding model (~90MB) | |
| RUN python -c "from sentence_transformers import SentenceTransformer; SentenceTransformer('all-MiniLM-L6-v2')" | |
| # Copy application files (excluding RAG database) | |
| COPY . . | |
| # Expose port 7860 | |
| EXPOSE 7860 | |
| # Run the app | |
| CMD ["python", "app.py"] | |