SuperAPIAI Directory

K8s-AIops

github.com · AI developer platforms

Governed Kubernetes operations for k3s, EKS, GKE and AKS: workloads, jobs, config, storage, networking and rollouts, with audit logging, dry-run and rollback.

Open website Alternatives
PricingOpen source开源项目(可免费自部署)
PlatformsLinux

About this tool

K8s-AIops is a community-maintained open-source project (MIT licensed) that provides governed Kubernetes operations capabilities for AI agents. It comes with the governance framework k8s_aiops.governance, requires no external skill families, and is a standalone tool.

Purpose and capabilities: Through MCP tools, it performs read and write operations on Kubernetes clusters, covering pods, deployments, statefulsets, daemonsets, replicasets, jobs/cronjobs, services, ingresses, endpoints, configmaps, secrets (names and keys only), PVC/PV/storageclasses, nodes, namespaces, events, as well as rollouts status/history/undo/pause/resume/set-image, and also pod/node describe, pod/node top, cluster health summaries, and read-only diagnostics and root cause analysis (pod health, workload readiness), labeling root causes by severity with the most severe first. It can be used with any cluster that a kubeconfig can connect to, including standard Kubernetes, k3s, EKS, GKE, AKS, kind, and minikube; authentication is entirely delegated to kubeconfig (client certificates, tokens, EKS/GKE/AKS exec plugins).

Governance mechanisms: Every call (both MCP and CLI alike) writes an audit record to ~/.k8s-aiops/audit.db; it provides token/runaway budget protection, revocation token records, and a risk_level risk rating label declared by each tool. Reversible writes record a reverse-undo description (such as scale_deployment scaling back to the original value, and cordon_node corresponding to uncordon_node). All MCP write tools support dry_run=True, returning a {"dryRun": true, ...} preview without touching the cluster and without recording an undo. delete_deployment is high risk, destructive CLI commands require secondary confirmation, medium-risk commands (deployment scale/restart) require one confirmation, and all writecommands support --dry-run. API text is processed through sanitize() (removing control/format characters and truncating).

Usage: It can be installed as a Claude Code plugin or an OpenClaw plugin (published on ClawHub; the gateway must be restarted after installation), and a single installation provides both the skill and the MCP server; the MCP server is obtained via uv and pinned to the package version declared by that plugin. It can also be used as a CLI or standalone MCP server, with credentials configured via k8s-aiops init, and named targets (multi-cluster/context) defined in ~/.k8s-aiops/config.yaml, which does not contain secrets; credentials come from kubeconfig. Note: The MCP server usually starts in a clean environment without shell environment variables, so K8S_AIOPS_HOME, K8S_AUDIT_APPROVED_BY, K8S_AUDIT_RATIONALE, and, if necessary, KUBECONFIG must be set in the env block of the MCP server configuration.

Limitations and notes: This tool only guarantees non-silence; it does not decide whether a write is allowed. Permissions are determined by the RBAC of the kubeconfig context or ServiceAccount, and there is no read-only switch, policy file, or approval gate. Risk levels are only labels, not gates. This tool does not handle or store cluster credentials and deliberately does not provide encrypted key storage (no secrets.enc, no secret CLI); this is a documented exception to the encrypted key storage pattern of this product line. Feature coverage focuses on common operations and is not yet exhaustive. Verification status: End-to-end testing has been done against a real kind cluster (v1.36); the newly added diagnostics/RCA tools in this release have only undergone simulated testing, see docs/VERIFICATION.md for details. This project is not affiliated with, endorsed by, or sponsored by CNCF, the Kubernetes project, or k3s/Rancher. Feature requests and contributions can be submitted to github.com/AIops-tools/K8s-AIops.

Up/Down to navigate · Enter to open · ESC to closeBrowse all tools