A CLI tool that scans Kubernetes clusters for issues and uses LLMs to explain problems in plain English.
k8sgpt-ai/k8sgpt-operator
A Kubernetes operator that deploys and manages K8sGPT, using an AI backend to diagnose cluster problems and optionally auto-remediate image pull failures.
- Stars
- 489
- Forks
- 148
- Open issues
- 29
- Last commit
- 15 hours ago
What is it?
K8sGPT Operator runs K8sGPT inside a Kubernetes cluster. You declare a K8sGPT custom resource that sets the AI backend, model, analysis scope and output integrations, and the operator creates and maintains the K8sGPT workload that scans the cluster and produces Result objects describing detected issues and suggested fixes.
Supported AI backends include OpenAI, Azure OpenAI, Amazon Bedrock and LocalAI, with credentials read from Kubernetes Secrets. The operator can monitor multiple clusters by referencing a kubeconfig, and it can use Azure Blob Storage or S3 as a remote cache. Analysis filters let you choose which resource types are analyzed, and a sink can forward results to Slack, Mattermost or CloudEvents endpoints.
An alpha, opt-in auto-remediation feature can repair selected workload image failures such as ImagePullBackOff. The operator itself computes and dry-runs the JSON patch against an approved image path, so the LLM does not write to the cluster directly.
Key features
- 01Manages a K8sGPT workload declaratively through a K8sGPT custom resource.
- 02Connects to OpenAI, Azure OpenAI, Amazon Bedrock and LocalAI backends.
- 03Monitors remote clusters through a kubeconfig reference, such as Cluster API clusters.
- 04Supports remote result caching with Azure Blob Storage or S3.
- 05Forwards analysis results to Slack, Mattermost or CloudEvents sinks.
- 06Offers opt-in, alpha auto-remediation for selected image pull failures.
Use cases
- Running continuous AI-assisted diagnostics across a Kubernetes cluster for an SRE team.
- Monitoring a fleet of Cluster API-managed clusters from a single management cluster.
- Sending cluster issue reports into Slack or Mattermost channels for on-call triage.
- Using a self-hosted LocalAI model so cluster data stays within your environment.
Quick start
- 1
Add the Helm repo
helm repo add k8sgpt https://charts.k8sgpt.ai/ - 2
Update Helm repos
helm repo update - 3
Install the operator into the cluster
helm install release k8sgpt/k8sgpt-operator -n k8sgpt-operator-system --create-namespace
Things to know
- Auto-remediation is alpha and opt-in, so it may change or be unsafe for production use.
- Running the example requires an OpenAI or other AI backend API key.
In collections
Topics
FAQ
- What is k8sgpt-operator?
- A Kubernetes operator that deploys and manages K8sGPT, using an AI backend to diagnose cluster problems and optionally auto-remediate image pull failures. K8sGPT Operator runs K8sGPT inside a Kubernetes cluster. You declare a K8sGPT custom resource that sets the AI backend, model, analysis scope and output integrations, and the operator creates and maintains the K8sGPT workload that scans the cluster and produces Result objects describing detected issues and suggested fixes.
- Is k8sgpt-operator free to use? What license does it have?
- k8sgpt-operator is open source under the Apache-2.0 license. Check the license terms before using it in commercial products.
- Is k8sgpt-operator still maintained?
- Actively maintained. The last commit to k8sgpt-operator was on Nov 7, 2026.
- What can I use k8sgpt-operator for?
- Running continuous AI-assisted diagnostics across a Kubernetes cluster for an SRE team. Monitoring a fleet of Cluster API-managed clusters from a single management cluster. Sending cluster issue reports into Slack or Mattermost channels for on-call triage. Using a self-hosted LocalAI model so cluster data stays within your environment.
- How do I install k8sgpt-operator?
- Add the Helm repo: helm repo add k8sgpt https://charts.k8sgpt.ai/ Update Helm repos: helm repo update Install the operator into the cluster: helm install release k8sgpt/k8sgpt-operator -n k8sgpt-operator-system --create-namespace
- Where can I get k8sgpt-operator?
- The source code and installation instructions are on GitHub: https://github.com/k8sgpt-ai/k8sgpt-operator
Summary generated by AI from the project's README. GitHub stats refresh daily.
Related projects
Open-source framework for building AI SRE agents that investigate production incidents across your own logs, metrics, traces and deploys.
A CLI and TUI that traces any process, port, container, or file back to the chain of systems that started it.
A free, open-source Kubernetes UI that runs as a single binary and includes a built-in MCP server so AI agents can read cluster state.
Kubernetes network observability tool that captures and indexes cluster traffic with eBPF, decrypts TLS, and exposes data to AI agents via MCP.
An open-source AI-native terminal for managing cloud and infrastructure, using natural language and agents to deploy, troubleshoot and automate services.