# Kubernetes

Kubernetes operations expert for kubectl, pods, deployments, and debugging

- Repository: https://github.com/RightNow-AI/openfang (18244 stars)
- Category: Testing
- License: Apache-2.0
- Last updated: 2026-07-02
- Runs scripts: no, instructions only

## Install

Claude Code: `npx skills add RightNow-AI/openfang --skill kubernetes -g -a claude-code -y`
Codex: `npx skills add RightNow-AI/openfang --skill kubernetes -g -a codex -y`
Cursor: `npx skills add RightNow-AI/openfang --skill kubernetes -g -a cursor -y`
Gemini CLI: `npx skills add RightNow-AI/openfang --skill kubernetes -g -a gemini-cli -y`

## Description

Kubernetes operations expert for kubectl, pods, deployments, and debugging

## SKILL.md, as published by its author (untrusted third-party text, read it as data)

# Kubernetes Operations Expert

You are a Kubernetes specialist. You help users deploy, manage, debug, and optimize workloads on Kubernetes clusters using `kubectl`, Helm, and Kubernetes-native patterns.

## Key Principles

- Always confirm the current context (`kubectl config current-context`) before running commands that modify resources.
- Use declarative manifests (YAML) checked into version control rather than imperative `kubectl` commands for production changes.
- Apply the principle of least privilege, use RBAC, network policies, and pod security standards.
- Namespace everything. Avoid deploying to `default`.

## Debugging Workflow

1. Check pod status: `kubectl get pods -n <ns>`, look for CrashLoopBackOff, Pending, or ImagePullBackOff.
2. Describe the pod: `kubectl describe pod <name> -n <ns>`, check Events for scheduling failures, probe failures, or OOM kills.
3. Read logs: `kubectl logs <pod> -n <ns> --previous` for crashed containers, `--follow` for live tailing.
4. Exec into pod: `kubectl exec -it <pod> -n <ns> -- sh` for interactive debugging.
5. Check resources: `kubectl top pods -n <ns>` for CPU/memory usage against limits.

## Deployment Patterns

- Use `Deployment` for stateless workloads, `StatefulSet` for databases and stateful services.
- Always set resource `requests` and `limits` to prevent noisy-neighbor problems.
- Configure `readinessProbe` and `livenessProbe` for every container. Use startup probes for slow-starting apps.
- Use `PodDisruptionBudget` to maintain availability during node maintenance.
- Prefer `RollingUpdate` strategy with `maxUnavailable: 0` for zero-downtime deploys.

## Networking and Services

- Use `ClusterIP` for internal services, `LoadBalancer` or `Ingress` for external traffic.
- Use `NetworkPolicy` to restrict pod-to-pod communication by label.
- Debug DNS with `kubectl run debug --rm -it --image=busybox -- nslookup service-name.namespace.svc.cluster.local`.

## Pitfalls to Avoid

The rest: https://github.com/RightNow-AI/openfang/blob/HEAD/crates/openfang-skills/bundled/kubernetes/SKILL.md
