feat: Add CI/CD pipeline with Docker build and K8s deployment

Add Dockerfile (multi-stage, python:3.11-slim + uv), K8s manifests
(Deployment + Service), and extend CI workflow with build-push-deploy
stages targeting Gitea registry and K3s.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
kappa
2026-02-07 22:19:32 +09:00
parent 07fdce0839
commit fb3a674eb8
4 changed files with 143 additions and 7 deletions

23
Dockerfile Normal file
View File

@@ -0,0 +1,23 @@
FROM python:3.11-slim AS builder
WORKDIR /app
COPY --from=ghcr.io/astral-sh/uv:latest /uv /usr/local/bin/uv
COPY haproxy_mcp/pyproject.toml haproxy_mcp/uv.lock ./haproxy_mcp/
RUN cd haproxy_mcp && uv pip install --system --no-cache -e .
COPY haproxy_mcp/ ./haproxy_mcp/
FROM python:3.11-slim
WORKDIR /app
COPY --from=builder /usr/local/lib/python3.11/site-packages /usr/local/lib/python3.11/site-packages
COPY --from=builder /usr/local/bin /usr/local/bin
COPY --from=builder /app/haproxy_mcp ./haproxy_mcp
EXPOSE 8000
ENTRYPOINT ["python", "-m", "haproxy_mcp"]