The readonly flag is enforced by the server, so a client configured that way cannot create, update or delete anything — node modifications included. Because the flag is set at launch rather than per call, two entries pointed at the same script with different arguments is the clean way to run it.
A Python control-plane server for Kubernetes: multi-cluster context switching, CRUD on the common resources, guided prompts, and a readonly mode that blocks every write.
- CRUD across the usual resources — Deployments, Services, Pods, ConfigMaps, Secrets, Ingresses, StatefulSets, DaemonSets, Roles, ClusterRoles, PersistentVolumes and Claims
- Multi-cluster context switching, so one connection reaches every cluster in your kubeconfig
- `--readonly` refuses `pod_create`, `deployment_delete`, `secret_update` and every other write, while `pod_list`, `pod_logs`, `deployment_get`, `secret_get` and the rest of the reads stay available
- Namespace work — create and delete namespaces, list everything inside one, manage labels and resource quotas
- Node work — read details and conditions, cordon and uncordon, label and taint, list the pods on a node
- Guided prompts: `troubleshoot_pod`, `deployment_guide`, `cluster_health_check`, `namespace_cleanup`
- Streamable HTTP transport as well as stdio, for managing clusters remotely
Python 3.13 or higher, the uv package manager, and cluster access through `~/.kube/config` or in-cluster config. Run `uv run --with "mcp[cli]>=1.28.0,<2" python k8s_pilot.py`, adding `--readonly` for safe inspection or `--transport streamable-http` for remote use. Or mount your kubeconfig into `ghcr.io/bourbonkk/k8s-pilot:latest`.
One command — docker run -i --rm \ -v ~/.kube/config:/root/.kube/config \ ghcr.io/bourbonkk/k8s-pilot:latest
