Retrieves resources from the hub cluster (current context)
Retrieves resources from managed clusters
Connects to a managed cluster using a specified ClusterRole
Accesses resources across multiple Kubernetes clusters via Open Cluster Management
The Multi-Cluster Kubernetes Gateway provides a robust interface for Generative AI systems to interact with and manage multiple Kubernetes clusters through the Model Context Protocol. It enables comprehensive operations on Kubernetes resources across clusters, streamlines multi-cluster management workflows, and delivers interactive cluster observability capabilities. This gateway serves as a bridge between AI systems and Kubernetes infrastructure, allowing for seamless resource retrieval from both hub and managed clusters, cluster connection using specified roles, and cross-cluster resource access via Open Cluster Management. The tool is designed to enhance AI-driven Kubernetes operations by providing a unified interface for multi-cluster environments.
To use the Multi-Cluster Kubernetes Gateway, you need to have Python and the necessary dependencies installed.
kubectl
on your systemKUBECONFIG
environment variable to point to your Kubernetes configurationThe simplest way to install and use the Multi-Cluster Kubernetes Gateway is with uvx
:
# Install uvx if you don't have it
pip install uvx
# Run the server
uvx multicluster-mcp-server@latest
You can also install the package manually using Poetry:
# Clone the repository
git clone https://github.com/yanmxa/multicluster-mcp-server.git
cd multicluster-mcp-server
# Install dependencies with Poetry
poetry install
# Run the server
poetry run python -m multicluster_mcp_server
To configure the Multi-Cluster Kubernetes Gateway in your MCP client (such as Claude, Anthropic Console, or other MCP-compatible tools), add the following configuration:
{
"mcpServers": {
"multicluster-mcp-server": {
"command": "uvx",
"args": [
"multicluster-mcp-server@latest"
]
}
}
}
For development purposes, you can use the MCP Inspector:
mcp dev ./src/multicluster_mcp_server/__main__.py
The Multi-Cluster Kubernetes Gateway uses your Kubernetes configuration to access clusters. By default, it uses the KUBECONFIG
environment variable to determine which cluster to connect to.
In a multi-cluster setup:
The gateway provides tools to:
The project roadmap includes plans to add:
If you encounter issues:
For more detailed information, refer to the GitHub repository.