Enables management of K3s lightweight Kubernetes clusters with full support for resource operations, monitoring, and troubleshooting through AI-powered natural language commands
Provides comprehensive Kubernetes cluster management through natural language interfaces, including resource CRUD operations, monitoring, scaling, troubleshooting, and multi-cloud support for EKS, AKS, GKE, RKE2, and K3s
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@MCP-K8sWizardshow me all pods in the production namespace"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
MCP-K8sWizard
The Kubernetes Wizard for Modern DevOps
Streamline your Kubernetes operations with AI-powered natural language interfaces and comprehensive DevOps automation.
π Overview
MCP-K8sWizard is a comprehensive Model Context Protocol (MCP) solution designed for professional DevOps teams. It provides natural language interfaces for complex Kubernetes workflows, enabling teams to manage clusters, monitor applications, and execute operational tasks efficiently through AI-powered conversations.
β¨ Key Features
π― Multi-Cloud Kubernetes Management
Universal Compatibility: Native support for EKS, AKS, GKE, RKE2, K3s, and standard Kubernetes distributions
Intelligent Cluster Detection: Automatic identification and configuration of cluster types and capabilities
Advanced Resource Management: Comprehensive CRUD operations across all Kubernetes resource types
Real-time Monitoring: Live cluster health, resource utilization, and performance metrics
π€ AI-Powered Operations
Natural Language Processing: Conversational interface for complex DevOps operations
Intelligent Troubleshooting: AI-driven diagnostics and step-by-step resolution guidance
Smart Prompts: Context-aware prompt suggestions for different scenarios
Automated Insights: Proactive identification of potential issues and optimization opportunities
π Security & Access Control
RBAC Integration: Full integration with Kubernetes RBAC and identity providers
Audit Logging: Comprehensive audit trails for all operations and access
Secure Communication: TLS encryption for all communications
Minimal Privilege: Secure by design with least privilege access patterns
ποΈ Architecture
MCP Protocol Integration
The following diagram shows how MCP-K8sWizard integrates with VSCode/Cursor AI through the Model Context Protocol:
βββββββββββββββ ββββββββββββββββ βββββββββββββββββββ
β Cursor AI βββββΆβ MCP Protocol βββββΆβ MCP-K8sWizard β
βββββββββββββββ ββββββββββββββββ β Server β
βββββββββββ¬ββββββββ
β
ββββββββββββββββββββββββββββββΌβββββββββββββββββββββββββββββ
β β β
βββββββββΌββββββββ βββββββββΌββββββββ βββββββββΌββββββββ
β Kubernetes β β Context β β Tool Handlers β
β API β β Manager β β β
βββββββββ¬ββββββββ βββββββββ¬ββββββββ βββββββββ¬ββββββββ
β β β
ββββββββββββββββββββββββββββββΌβββββββββββββββββββββββββββββ
β β β
βββββββββΌββββββββ βββββββββΌββββββββ βββββββββΌββββββββ
β K8s Tools β β Kubectl Tools β β Prompt Tools β
β β β β β β
β β’ Cluster Infoβ β β’ Resource β β β’ Diagnostics β
β β’ Resources β β CRUD β β β’ Troubleshootβ
β β’ Logs/Events β β β’ Scaling β β β’ Optimizationβ
β β’ Pod Exec β β β’ Rollouts β β β’ Security β
βββββββββββββββββ βββββββββββββββββ βββββββββββββββββComponent Architecture
The internal architecture of MCP-K8sWizard follows a layered approach:
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β MCP Layer β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ€
β MCP Server βββΆ Tool Registry βββΆ Request Router β
ββββββββββββββββββββββββββββββββββββ¬βββββββββββββββββββββββββββββββββββββββββββ
β
ββββββββββββββββββββββββββββββββββββΌβββββββββββββββββββββββββββββββββββββββββββ
β Core Services β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ€
β Context Manager βββΆ K8s Client Manager βββΆ Resource Handler β
β β β β β
β βββββββββββββββββββββββββΌββββββββββββββββββββββββββββββββββββββββββββ
β β β
β Config Manager βββΆ Event Monitor βββΆ Kubernetes API β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β
βββββββββββββββββββββββββββββββββββΌββββββββββββββββββββββββββββββββββββββββββββ
β Tool Handlers β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ€
β K8s Tools β Kubectl Tools β Prompt Tools β Context Tools β
β βββββββββ β ββββββββββββ β βββββββββββ β ββββββββββββ β
β β’ Cluster Ops β β’ Resource Mgmt β β’ AI Guidance β β’ Multi-Clusterβ
β β’ Monitoring β β’ CRUD Ops β β’ Diagnostics β β’ Context Sw. β
β β’ Debugging β β’ Scaling β β’ Optimization β β’ Health Chk β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββπ οΈ Available Tools
Kubernetes Management Tools (37 Total)
Category | Tools | Description |
Kubernetes Operations (14) |
| Direct Kubernetes API operations, monitoring, and debugging |
Kubectl Operations (12) |
| Full CRUD operations, scaling, rollouts, and resource management via kubectl |
Context Management (4) |
| Multi-cluster context switching and management |
AI-Powered Guidance (7) |
| Intelligent diagnostic, optimization, and troubleshooting prompts |
π Quick Start
Prerequisites
Go 1.25.1 or later
Kubernetes cluster access (kubeconfig configured)
VSCode/Cursor AI with MCP support
macOS or Linux operating system
Installation
For detailed installation instructions, see our comprehensive Installation Manual.
Quick Setup:
Clone and install
git clone https://github.com/your-org/mcp-k8swizard.git cd mcp-k8swizard make installConfigure Cursor AI Add to your
~/.cursor/mcp.json:{ "mcpServers": { "k8s-wizard": { "command": "/path/to/mcp-k8swizard", "args": ["--verbose"] } } }Restart Cursor AI and start using natural language commands!
π Need detailed instructions? Check out our Installation Manual for step-by-step setup, troubleshooting, and advanced configuration options.
Basic Usage
# Check cluster health
"Show me the status of all my Kubernetes clusters"
# List resources
"List all pods in the production namespace"
# Debug issues
"Get logs from the failing pod in the web-app deployment"
# Scale applications
"Scale the frontend deployment to 5 replicas"
# Troubleshoot problems
"Help me diagnose why my pod is stuck in Pending state"π Natural Language Examples
Cluster Management
"Show me all my Kubernetes clusters and their health status"
"Check the resource usage across all nodes in my EKS cluster"
"List all namespaces and their resource quotas"Resource Operations
"Create a new namespace called 'staging'"
"List all deployments with more than 3 replicas"
"Show me the configuration of the nginx service"
"Delete all pods with the label 'app=test'"Debugging & Troubleshooting
"Get the logs from the last 100 lines of the api-server pod"
"Show me events related to the failing deployment"
"Execute a shell command in the debug container"
"Why is my pod not starting? Help me troubleshoot"Scaling & Updates
"Scale the web-app deployment to 10 replicas"
"Roll out a new version of the frontend service"
"Pause the rollout of the database deployment"
"Show me the rollout history for the api service"π§ Configuration
Environment Variables
Variable | Description | Default |
| Path to kubeconfig file |
|
| Default Kubernetes context | Current context |
| Logging level (DEBUG, INFO, WARN, ERROR) |
|
| Log file path |
|
Command Line Options
./mcp-k8swizard --help
Options:
-log-level string
Set log level (DEBUG, INFO, WARN, ERROR)
-verbose
Enable verbose logging (equivalent to DEBUG level)
-version
Show version information
-help
Show help informationπ€ Contributing
We welcome contributions! Please see our Contributing Guidelines for details.
Development Setup
Fork the repository
Create a feature branch
Make your changes
Submit a pull request
Development Commands
# Build the project
make build
# Install dependencies
make deps
# Format code
make fmt
# Run linter
make lint
# Run go vet
make vet
# Clean build artifacts
make cleanCode Style
Follow Go standard formatting (
gofmt)Use meaningful variable and function names
Add comments for public functions
π License
This project is licensed under the MIT License - see the LICENSE file for details.
π Acknowledgments
Model Context Protocol for the MCP specification
Kubernetes for the amazing container orchestration platform
Go for the excellent programming language
The open-source community for inspiration and support
π Documentation
Manuals
Installation Manual - Complete setup guide for Cursor AI integration
Configuration Guide - Advanced configuration options
Troubleshooting Guide - Common issues and solutions
API Reference - Complete tool documentation
Quick Links
Getting Started: See Installation Manual for detailed setup
Configuration: Advanced options in Configuration Guide
Troubleshooting: Common issues in Troubleshooting Guide
π Support
Documentation: Wiki
Issues: GitHub Issues
Discussions: GitHub Discussions
Made with β€οΈ for the Kubernetes community