pypi janus-mcp-serverstdioApache-2.0updated 10d ago
Two faces. One cluster. No exposed keys.
Was kannst du mit Janus machen?
What is Janus?
Janus is an MCP (Model Context Protocol) server that gives AI assistants a safe, controlled window into your Kubernetes clusters. It runs locally, holds your KUBECONFIG close to its chest, and lets the LLM operate through carefully‑scoped tools — so you get the power of an AI copilot without ever shipping a token, certificate, or API server URL to a third‑party model.
Named after the Roman god of gateways (who famously looks both ways at once), Janus faces the LLM with clean, declarative tool definitions, and faces your cluster with full administrative access — while ensuring the two never meet inappropriately.
The problem
LLMs are incredibly useful for debugging, operating, and reasoning about Kubernetes. But the moment you paste a KUBECONFIG into a chat window or send it to an external API, you’ve handed over the keys to your kingdom. For most organisations, that’s a non‑starter.
Self‑hosting a model helps, but not everyone can or wants to run frontier‑grade LLMs locally. Janus gives you a third path: keep the credentials on‑prem (or on your laptop) and let the remote model work with sanitised, high‑level cluster information only.
How it works
┌──────────────┐ ┌────────────────┐ ┌───────────────┐
│ LLM Client │<─────>│ Janus (local) │<─────>│ Kubernetes │
│ (Claude, │ MCP │ holds the │ k8s │ API Server │
│ VS Code, │ │ KUBECONFIG │ API │ │
│ custom) │ │ redacts output │ │ │
└──────────────┘ └────────────────┘ └───────────────┘
- Tools, not text dumps — Janus exposes a set of MCP tools (
get_pods,describe_deployment,get_events, etc.) that the LLM can call. It never hands over raw cluster state. - Automatic redaction — Every response from the Kubernetes API is sanitised. Secrets, tokens, env‑var values, and sensitive metadata are stripped before the LLM ever sees them.
- Human approval for writes — Read‑only operations are instant. Destructive actions (restart, scale, delete) require an explicit confirmation step inside your MCP client. The LLM can propose the action, but a human has to pull the trigger.
- Scoped access — Janus can be locked to a specific namespace, set of clusters, or even a subset of resources, adding an extra safety net beyond whatever your
KUBECONFIGpermits.
Features
- 🔒 Zero‑credential exposure — your
KUBECONFIGnever leaves the process running Janus. - 🔍 Rich read‑only diagnostics — pods, workloads, services, events, logs, endpoints, quotas, live CPU/memory usage vs requests (
kubectl top+), and rollout history with sanitized template diffs (“what changed recently?”). - ✍️ Guarded write operations — rollout restart & rollback, scale, delete‑pod (UID‑bound), CronJob suspend/resume/trigger, node cordon — every one behind out‑of‑model human approval, none registered unless the operator enables it.
- 🧹 Pluggable redaction engine — sensible defaults, easily extended to your own patterns.
- 🧭 Cluster overview, two ways — the
get_cluster_summarytool, plus a pinnablecluster://summaryMCP resource that gives the LLM context without a flurry of tool calls. - 🩺 Guided triage — the
diagnose_namespaceprompt template walks the model through a structured investigation (overview → pods → warnings → targeted logs → diagnosis) in any client that supports MCP prompts. - 🧪 Works with any MCP client — Claude Code, Claude Desktop, VS Code, Codex, or your own agent loop.
Roadmap
- Distribution ✓ — PyPI
janus-mcp-server· containerghcr.io/tonylchang/janus-mcp· Homebrewtonylchang/tap/janus-mcp - Streamable HTTP sidecar mode (bearer token + Origin validation)
Quick start
uv tool install janus-mcp-server # or: pipx install janus-mcp-server
# brew install tonylchang/tap/janus-mcp
mkdir -p ~/.config/janus-mcp
curl -fsSL https://raw.githubusercontent.com/tonylchang/janus-mcp/main/examples/config.yaml \
-o ~/.config/janus-mcp/config.yaml
$EDITOR ~/.config/janus-mcp/config.yaml # set your kubeconfig context + namespaces
# register with Claude Code:
claude mcp add kubernetes -- janus-mcp serve
No Python toolchain? The same server ships as a container image:
claude mcp add kubernetes -- docker run -i --rm \
-v ~/.kube/config:/home/janus/.kube/config:ro \
-v ~/.config/janus-mcp:/home/janus/.config/janus-mcp:ro \
ghcr.io/tonylchang/janus-mcp:latest
Registration recipes for Claude Desktop, VS Code/Copilot, Codex CLI, and Cursor are in the quick start guide.
Now ask your AI assistant something like: “Why are pods crashing in the prod namespace?”
Janus will fetch the relevant information, sanitise it, and the LLM will walk you through what’s happening — safely.
Docs
- Operator runbook — install, least-privilege RBAC, approvals, audit log, troubleshooting
- Threat model — the five security invariants and how CI verifies them
rbac/— least-privilege manifests (note what is absent: secrets — nowhere, ever)
Janus is currently in active development.
Installation
Janus zu deinem Client hinzufügen. Wähl den, den du nutzt.
claude mcp add janus-mcp-server -- uvx janus-mcp-servercodex mcp add janus-mcp-server -- uvx janus-mcp-serveramp mcp add janus-mcp-server -- uvx janus-mcp-server{
"mcpServers": {
"janus-mcp-server": {
"command": "uvx",
"args": [
"janus-mcp-server"
]
}
}
}Add to `claude_desktop_config.json`, then restart Claude Desktop.
{
"mcpServers": {
"janus-mcp-server": {
"command": "uvx",
"args": [
"janus-mcp-server"
]
}
}
}Add to `~/.cursor/mcp.json`, or `.cursor/mcp.json` for a single project.
code --add-mcp '{"name":"janus-mcp-server","command":"uvx","args":["janus-mcp-server"]}'Or add the block manually to `.vscode/mcp.json` under `servers`.
{
"mcpServers": {
"janus-mcp-server": {
"command": "uvx",
"args": [
"janus-mcp-server"
]
}
}
}Add to `~/.codeium/windsurf/mcp_config.json`.
{
"mcpServers": {
"janus-mcp-server": {
"command": "uvx",
"args": [
"janus-mcp-server"
]
}
}
}Add to `cline_mcp_settings.json` via the MCP Servers panel.
{
"mcpServers": {
"janus-mcp-server": {
"command": "uvx",
"args": [
"janus-mcp-server"
]
}
}
}Add to `~/.gemini/settings.json`.
{
"mcpServers": {
"janus-mcp-server": {
"type": "local",
"command": "uvx",
"args": [
"janus-mcp-server"
],
"tools": [
"*"
]
}
}
}Add to `~/.copilot/mcp-config.json`, or run `/mcp add` inside the CLI.
{
"context_servers": {
"janus-mcp-server": {
"command": {
"path": "uvx",
"args": [
"janus-mcp-server"
]
}
}
}
}Add to your Zed `settings.json`.
uvx janus-mcp-serverRun `goose configure`, choose **Add Extension → Command-line Extension**, and paste this command.
Score
39 / 100
Unvollständig
- Dokumentation25/25
- Pflege19/25
- Vertrauen13/20
- Funktionsumfang0/15
- Installation12/15
- Documents what it does and how to connect
- Has a resolvable package or endpoint
- Exposes at least one tool, prompt or resource
- README has substantive content
- Includes a code example
- Documents its configuration
- Mentions credentials or security posture
- Last commit 2 days ago
- Has a release history
- Repository is not archived
- Licensed Apache-2.0
- Namespace verified in the official MCP registry
- Claimed by its owner
- Published under an organisation
- 0 tool(s) documented
- Provides prompt templates
- Provides resources
- 12 documented install method(s)
- Published to a package registry
- Offers a hosted endpoint — no local install
Versionsverlauf
| Versionen | Veröffentlicht |
|---|---|
| 0.4.1Aktuell | 18. Aug. 2026 |