Flux159/mcp-server-kubernetes
MCP Server for kubernetes management commands
What it solves
It allows AI assistants (like Claude, Cursor, or VS Code extensions) to directly interact with and manage Kubernetes clusters. Instead of a user manually running commands in a terminal, the AI can perform cluster operations, troubleshoot pods, and manage deployments through a standardized protocol.
How it works
The project implements the Model Context Protocol (MCP), acting as a bridge between an AI client and the Kubernetes API. It leverages kubectl and helm installed on the host system to execute commands. It supports multiple authentication methods via kubeconfig and provides a set of specialized tools for the AI to call, including resource management, log retrieval, and port forwarding.
Who it’s for
DevOps engineers, SREs, and developers who want to use AI agents to automate Kubernetes cluster management, perform diagnostics, and handle routine infrastructure operations.
Highlights
- Comprehensive Toolset: Provides a unified API for
kubectloperations (get, describe, apply, delete, scale, patch) andhelmchart management. - Safety Controls: Includes a non-destructive mode that disables all destructive operations (like deleting pods or namespaces) for read-only or create-only access.
- Automated Diagnostics: Features a specialized
/k8s-diagnoseprompt to guide AI through systematic pod troubleshooting. - Observability: Optional OpenTelemetry integration for distributed tracing of all tool calls to backends like Jaeger or Grafana Tempo.
- Security: Implements secrets masking to prevent sensitive data from being exposed in
kubectl get secretsoutputs.
Related
- Project
- Project
- Project
- Project
- Project