MCP.so
Sign In

Mcp Kubernetes Server

@ductnn

About Mcp Kubernetes Server

A lightweight MCP server that provides natural language processing and API access to Kubernetes clusters, combining both kubectl commands and Kubernetes Python client.

Basic information

Category

Cloud & Infrastructure

License

MIT license

Runtime

python

Transports

stdio

Publisher

ductnn

Submitted by

Duc Tran

Config

Add this server to your MCP-compatible client using the configuration below.

{
  "mcpServers": {
    "mcp-kubernetes-server-ductnn": {
      "command": "uv",
      "args": [
        "venv",
        ".venv"
      ]
    }
  }
}

Tools

No tools detected

We auto-extract tools from the README. The maintainer can list them under a ## Tools heading to populate this section.

Overview

What is Mcp Kubernetes Server?

A lightweight MCP server that provides natural language processing and API access to Kubernetes clusters, combining kubectl commands with the Kubernetes Python client. It is intended for developers and operators who want to manage Kubernetes resources through AI assistants or direct API calls.

How to use Mcp Kubernetes Server?

Install Python 3.11+, ensure kubectl is configured locally, and install UV. Clone the repository, create a virtual environment with UV, and install dependencies. Run the server with uv run main.py or configure it as an MCP server in tools like Claude Desktop by editing the claude_desktop_config.json.

Key features of Mcp Kubernetes Server

  • Natural language interface: convert plain English queries to kubectl commands
  • Full CRUD operations for namespaces, pods, and deployments
  • Dual execution mode: kubectl command integration and Kubernetes Python client
  • Namespace validation (DNS-1123 compliant)
  • Label filtering and grace period control
  • Automatic command fallback for unsupported queries

Use cases of Mcp Kubernetes Server

  • Manage Kubernetes clusters through AI assistants like Claude Desktop
  • Perform common resource operations using natural language queries
  • Automate pod, deployment, and namespace creation and deletion
  • Inspect cluster resources across all namespaces
  • Scale deployments and modify labels/annotations via API endpoints

FAQ from Mcp Kubernetes Server

What are the prerequisites for using this server?

Python 3.11+, access to a Kubernetes cluster, kubectl configured locally, and UV installed.

How does the natural language processing work?

The server uses a natural language processor (nl_processor) that converts phrases like “Show me all pods” into equivalent kubectl commands. If a query is unsupported, it falls back to a general resource listing.

Can I create or delete Kubernetes resources with this server?

Yes, the server provides full CRUD operations via dedicated API endpoints for pods, deployments, and namespaces, including graceful deletion and force delete options.

How do I integrate this server with Claude Desktop?

Edit your claude_desktop_config.json to add a “kubernetes” MCP server entry pointing to the uv command and the project directory, then restart Claude Desktop.

Does it require kubectl or is the Python client enough?

It supports both execution modes. kubectl must be configured locally, but the server also uses the official Kubernetes Python SDK for operations.

Comments

More Cloud & Infrastructure MCP servers