Labsco
MCP SERVER

Kubernetes MCP Server

by kkb0318

Inspect a Kubernetes cluster with an assistant that has no way to change it — resources, events, pod logs and contexts, read-only by construction.

Containers, Kubernetes & Cluster Operations
Summary
Cluster debugging with the write path removed.

It answers the questions a triage session asks — what is running, what does this object look like, what do the logs and events say — over a connection that cannot change the cluster.

What it is

A Go server that talks to your cluster through your kubeconfig and deliberately publishes no write path. It lists and filters any resource type including custom resources, describes one in detail, pulls pod logs, reads events, and moves between contexts.

What you get
  • list_resources lists and filters resources, with label and field selectors, API group filtering and paging
  • describe_resource returns the full detail of one resource
  • get_pod_logs retrieves pod logs with filtering, for when the description is not enough
  • list_events returns cluster events, filtered — usually where a failing rollout explains itself
  • list_contexts returns every context in your kubeconfig, so a multi-cluster setup stays one connection
  • Custom resources behave like built-ins, and resources can be found by an API group substring — "flux" for FluxCD, "argo" for ArgoCD
  • There are no write tools, so the most an assistant can do here is read
Requirements

Cluster access through a valid kubeconfig; the server uses ~/.kube/config by default and takes a custom path in the client config. Install with `go install github.com/kkb0318/kubernetes-mcp@latest` (Go 1.24 or newer) or build from source.

Setup effort

One command — go install github.com/kkb0318/kubernetes-mcp@latest