
As with most Mondays, we start with a job and task in mind but quickly as we begin catching up on news from the weekend, we find some interesting rabbit holes to investigate. This Monday morning was no different but I also do not usually have the urge to share such information.
As you all know AI is everywhere, I mean if you do not have a chatbot can you even spell AI!?
My morning started with reading up on a tool called ‘kubectl-cli’ from Google – https://github.com/GoogleCloudPlatform/kubectl-ai
I had seen others doing similar things so was intrigued when Google come out with a project, to name one that I had on my list would be k8sgpt – https://k8sgpt.ai/
K8sGPT is for understanding and debugging what’s going wrong inside a Kubernetes cluster.
kubectl-ai is for interacting with the cluster more easily, translating your intent into commands.
The premise of these tools is the ability to use AI to manage your Kubernetes cluster and resources leveraging natural language. For me this does a few things, the barrier to entry in learning Kubernetes is the overwhelming CLI options and variations, albeit this is a superpower in itself its a challenge for many people that do not have that background. Kubernetes does have a complexity to it, its why it is so diversified in the fields we see it which means by the nature of it, it can do many things which brings complexity. My dad used to say to me “children should be seen but not heard” never really understood that saying but Kubernetes is the same… should be used but not seen… by most people… Maybe that works, who knows…
By adding the ability to query your cluster and instruct tasks via this and other tools we now dont need to memorise everything about kubectl and we can instruct it to run this and do that, or provide me feedback on this.
I started off trying to use the Google AI Studio API key but initially it said the model was overloaded and then the key seemed to be wrong.

So I then went and tried the ability to use a local model with Ollama but I only had my MacBook and you need to download the gemini pro model which is around 8GB and with no GPU I need to wait to do this with my desktop PC… maybe a video on this setup.
You can bring many models and services, so I used my trusty OpenAI key and got to work… exporting the key and asking some initial questions.

As I am focused an interested in the world of data management within Kubernetes I wanted to see how we could go about creating a backup policy and what I needed to provide to make this work.

Meanwhile up to this point, we were barely touching the spending on our OpenAI key…

As the $$ are low, we can ask a few more things about our backup policies

I then thought, what about getting some insight into our cluster, whats the health of things… maybe things I have not been able to see yet, I can just ask right and get a simple output of things I need to troubleshoot.

Very quick post to start with, but I am now intrigued into this simplification. Maybe I could release some of that RAM in my brain where I am storing all those kubectl commands and store something else.
As a beginner to Kubernetes you have the best chance to accelerate on here and get to grips with a lot more much faster… Just ask it to deploy your nginx deployment and expose it via a service… no longer do you have to worry about the YAML and kubectl commands.
My final thought, this is great for home labs and dev environments… Still be mindful running this on anything important… I also want to give K8sGPT a try as I can see this might do the same and some more things here.
I am sure there are many other tools popping up in this area, but as a quick comparison of the two I created this table.
Feature | K8sGPT | kubectl-ai |
---|---|---|
Purpose | Diagnoses and explains Kubernetes cluster issues | Helps write and understand kubectl |
Focus | Cluster health, error analysis, and troubleshooting | Command-line assistant for kubectl |
AI Role | Uses AI to explain root causes and suggest fixes | Uses AI to translate natural language to kubectl |
Installation | CLI tool + CRDs (optional for full diagnostics) | kubectl |
Integration | Can run inside clusters; supports multi-language output | Works locally in the terminal as a plugin |
Common Use Case | Debugging failed pods, misconfigurations, alerts | Helping users construct or correct kubectl |