rancher-mcp
v1.82.0Capability-aware MCP server for Rancher-managed Kubernetes: discovery, resources, workflows.
Values you need
| Variable | What it is | |
|---|---|---|
RANCHER_URL | required | Rancher server URL (single-instance mode) |
RANCHER_TOKEN | required secret | Rancher API token (token-xxxxx:yyyyyyyyy) |
RANCHER_VERIFY_SSL | optional | Verify TLS certificates (default true) |
RANCHER_INSTANCES_JSON | optional secret | Multi-instance config JSON (overrides single-instance mode; supports per-instance read_only) |
PyPI (uvx) discovery passed
Requires uv (https://docs.astral.sh/uv/)
Run in a terminal
claude mcp add rancher-mcp -e 'RANCHER_TOKEN=<RANCHER_TOKEN>' -e 'RANCHER_URL=<RANCHER_URL>' -- uvx rancher-mcp==1.82.0Add to
claude_desktop_config.json{
"mcpServers": {
"rancher-mcp": {
"args": [
"rancher-mcp==1.82.0"
],
"command": "uvx",
"env": {
"RANCHER_TOKEN": "<RANCHER_TOKEN>",
"RANCHER_URL": "<RANCHER_URL>"
}
}
}
}Add to
~/.cursor/mcp.json{
"mcpServers": {
"rancher-mcp": {
"args": [
"rancher-mcp==1.82.0"
],
"command": "uvx",
"env": {
"RANCHER_TOKEN": "<RANCHER_TOKEN>",
"RANCHER_URL": "<RANCHER_URL>"
}
}
}
}Add to
.vscode/mcp.json{
"inputs": [
{
"description": "RANCHER_TOKEN",
"id": "rancher-token",
"password": true,
"type": "promptString"
},
{
"description": "RANCHER_URL",
"id": "rancher-url",
"password": true,
"type": "promptString"
}
],
"servers": {
"rancher-mcp": {
"args": [
"rancher-mcp==1.82.0"
],
"command": "uvx",
"env": {
"RANCHER_TOKEN": "${input:rancher-token}",
"RANCHER_URL": "${input:rancher-url}"
},
"type": "stdio"
}
}
}Add to
~/.codex/config.toml[mcp_servers.rancher-mcp]
command = "uvx"
args = ["rancher-mcp==1.82.0"]
env = { "RANCHER_TOKEN" = "<RANCHER_TOKEN>", "RANCHER_URL" = "<RANCHER_URL>" }For AI agents
- Ask the user for: RANCHER_URL, RANCHER_TOKEN. Never invent or guess these values; secrets go into the client config, not into chat logs.
- Pick the user's MCP client and apply the matching config from the first install method (it is the one verified by the smoke test when available).
- Restart or reload the client so it starts the server.
- Verify: the server should expose these tools: rancher_instance_list, rancher_capability_domain_list, rancher_server_profile_get, rancher_server_health, rancher_server_version, rancher_api_plane_list, rancher_norman_schema_list, rancher_norman_schema_get, ….
- If it fails, check that the required runtime is installed (uv (https://docs.astral.sh/uv/)) and that the values above are set.
Machine-readable: install.md · manifest.json