From anthropic-pack
Deploys Claude API services to Docker, GCP Cloud Run, Kubernetes with secret management, health checks, rollbacks, and error handling.
How this skill is triggered — by the user, by Claude, or both
Slash command
/anthropic-pack:anth-deploy-integrationThis skill is limited to the following tools:
The summary Claude sees in its skill listing — used to decide when to auto-load this skill
Deploy Claude API integrations with proper secret management, health checks, and rollback procedures across Docker, GCP Cloud Run, and Kubernetes.
Deploy Claude API integrations with proper secret management, health checks, and rollback procedures across Docker, GCP Cloud Run, and Kubernetes.
FROM python:3.12-slim
WORKDIR /app
COPY requirements.txt .
RUN pip install --no-cache-dir -r requirements.txt
COPY src/ ./src/
ENV ANTHROPIC_API_KEY=""
EXPOSE 8000
CMD ["uvicorn", "src.main:app", "--host", "0.0.0.0", "--port", "8000"]
# src/main.py
from fastapi import FastAPI, HTTPException
import anthropic
app = FastAPI()
client = anthropic.Anthropic()
@app.get("/health")
async def health():
try:
count = client.messages.count_tokens(
model="claude-haiku-4-20250514",
messages=[{"role": "user", "content": "ping"}]
)
return {"status": "healthy", "api": "connected"}
except Exception as e:
raise HTTPException(503, detail=str(e))
echo -n "sk-ant-api03-..." | gcloud secrets create anthropic-key --data-file=-
gcloud run deploy claude-service \
--image gcr.io/my-project/claude-service \
--set-secrets ANTHROPIC_API_KEY=anthropic-key:latest \
--min-instances 1 --max-instances 10 \
--memory 512Mi --timeout 120s
apiVersion: apps/v1
kind: Deployment
metadata: { name: claude-service }
spec:
replicas: 3
strategy: { type: RollingUpdate, rollingUpdate: { maxUnavailable: 1 } }
template:
spec:
containers:
- name: app
env:
- name: ANTHROPIC_API_KEY
valueFrom:
secretKeyRef: { name: anthropic-secrets, key: api-key }
livenessProbe:
httpGet: { path: /health, port: 8000 }
periodSeconds: 30
# Cloud Run
gcloud run services update-traffic claude-service --to-revisions=PREVIOUS=100
# Kubernetes
kubectl rollout undo deployment/claude-service
| Issue | Cause | Fix |
|---|---|---|
| Container crash on start | Missing API key env var | Verify secret binding |
| Health check fails | Key invalid in prod | Test key with curl |
| 429 after scaling up | More replicas = more RPM | Shared rate limiter (Redis) |
For event-driven patterns, see anth-webhooks-events.
npx claudepluginhub jeremylongshore/claude-code-plugins-plus-skills --plugin anthropic-packImplements Claude API patterns for serverless (Lambda), microservices (FastAPI WS), queues (Celery), and edge deployments using Python.
Deploys Mistral AI apps to Vercel Edge/Serverless, Docker, and Cloud Run with secret configuration and code examples for production.
Packages Claude Code as an OCI image via mise and deploys it as a kubernetes-sigs/agent-sandbox SandboxTemplate workload, with session persistence and egress allowlisting.