Files
MarioGLealPandClaude Opus 5.5 4f25dd39c2
CI / test (push) Successful in 8s
CI / deploy (push) Successful in 5s
import from clockmost-infra projects/poe2rag/app (WP-53 phase 2)
Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
Claude-Session: https://claude.ai/code/session_01GZZ5ztbBNFM4DjL1zF4dua
2026-10-02 14:15:42 +01:00

24 lines
734 B
Docker

# poe2rag backend — FastAPI + model2vec + sqlite-vec, serving the built UI.
FROM ghcr.io/astral-sh/uv:python3.12-bookworm-slim
ENV UV_COMPILE_BYTECODE=1 \
UV_LINK_MODE=copy \
UV_NO_CACHE=1 \
HF_HOME=/models \
POE2_DB=/data/poe2.db
WORKDIR /app
# deps first for layer caching
COPY pyproject.toml uv.lock ./
RUN uv sync --frozen --no-dev --group server
# bake the embedding model into the image so the container is offline-capable
RUN uv run python -c "from model2vec import StaticModel; StaticModel.from_pretrained('minishlab/potion-retrieval-32M')"
COPY server/ ./server/
EXPOSE 8000
CMD ["uv", "run", "--no-dev", "--group", "server", "uvicorn", "server.app:app", \
"--host", "0.0.0.0", "--port", "8000"]