k8s-operations
Installation
SKILL.md
k8s-operations
Day-2 operations for self-hosted Kubernetes: probes, rollouts, deployment automation, and cluster hardening.
Probe Decision
| Probe | Purpose | Failure action | Use when |
|---|---|---|---|
| startupProbe | Container started successfully | Restart container; blocks liveness/readiness | App takes >30s to initialize (slow JVM, model loading) |
| livenessProbe | Container is still healthy | Restart container | Deadlocks, memory leaks, stuck processes |
| readinessProbe | Container is ready to serve traffic | Remove from Service endpoints (no restart) | Always — prevents traffic to unready pods |
Recommendation: Always define both readinessProbe and livenessProbe. Use startupProbe only for slow-starting containers. Never use livenessProbe alone — without readinessProbe, traffic routes to pods that aren't ready.
Probe interaction: readinessProbe and livenessProbe run independently. A pod can be restarted (liveness failure) while still passing readiness, or removed from endpoints (readiness failure) while liveness succeeds. Set livenessProbe.failureThreshold higher than readinessProbe.failureThreshold to give the pod a chance to recover before restarting.