RepoAnalyzer / Dockerfile
Manisankarrr's picture
fix: pin numpy to 1.26.4 for faiss compatibility
2a3c1c9
Raw
History Blame Contribute Delete
719 Bytes
# ---------- Frontend Build ----------
FROM node:18 AS frontend-builder
WORKDIR /app/frontend
COPY frontend/package*.json ./
RUN npm install
COPY frontend/ .
RUN npm run build
# ---------- Backend ----------
FROM python:3.10-slim
WORKDIR /app
RUN apt-get update && \
apt-get install -y git && \
rm -rf /var/lib/apt/lists/*
RUN pip install --upgrade pip
COPY requirements.txt .
RUN pip install --no-cache-dir -r requirements.txt
RUN python -c "import numpy; import faiss; print(numpy.__version__)"
COPY backend ./backend
COPY --from=frontend-builder /app/frontend/dist ./frontend/dist
EXPOSE 7860
ENV PYTHONPATH=/app/backend
CMD ["uvicorn", "backend.main:app", "--host", "0.0.0.0", "--port", "7860"]