All skills
Skillintermediate
generate manifest
Generate production-ready Kubernetes manifests from application configuration.
Claude Code Knowledge Pack7/10/2026
Overview
Generate production-ready Kubernetes manifests from application configuration.
Steps
- Analyze the application:
- Read Dockerfile for container port, health check, and entrypoint.
- Read environment variable requirements from
.env.example. - Detect service dependencies from docker-compose or config files.
- Generate manifests:
- Namespace definition.
- Deployment with resource limits, probes, and rolling update strategy.
- Service (ClusterIP for internal, LoadBalancer for external).
- ConfigMap for non-sensitive configuration.
- Secret template for sensitive values.
- Ingress with TLS if external access is needed.
- HPA for auto-scaling based on CPU/memory.
- Add Kustomize base and overlays for dev/staging/production.
- Validate manifests:
kubectl apply --dry-run=client -f .. - Write files to
k8s/ordeploy/directory.
Format
apiVersion: apps/v1
kind: Deployment
metadata:
name: <app>
labels:
app.kubernetes.io/name: <app>
app.kubernetes.io/version: <version>
Rules
- Always set CPU and memory requests and limits.
- Include readiness and liveness probes for every container.
- Use
app.kubernetes.io/label conventions. - Never hardcode secrets; use Secret resources or external-secrets operator.
- Set
securityContextwith non-root user and read-only filesystem where possible.