Feature requestPending

Kubernetes MCP: pod network health check, server-side apply and secrets created without passing values through the agent

thanhlinh9191Posted

The problem

Follow-up to FEAT-106, which shipped in 1.47.0. We tested the new tools on our 4-node k3s cluster (1 server + 3 agents over Tailscale): cordon/uncordon, drain and delete-node dry runs with their guards, label, taint, delete_resource dry run, events, describe, exec, helm list/uninstall dry run and etcd snapshot list all work well. Day-to-day work and node maintenance no longer need raw kubectl. Three gaps remain, each one hit on the real cluster this month.

  1. POD NETWORK HEALTH IN k8s_overview

k8s_overview reports "Cluster healthy" from node Ready status. For two days our flannel VXLAN was dead on all 4 nodes (tailscale0 was recreated, flannel kept logging "external interface not found" and flannel.1 disappeared), yet every node stayed Ready, so the overview would have said healthy while cross-node pod traffic failed. Please add a pod network check: the CNI interface exists on each node (flannel.1 for k3s), and optionally a cross-node probe (each node reaches another node's pod CIDR). Report it as an issue in health, and ideally as its own tool, k8s_network_check.

  1. SERVER-SIDE APPLY IN k8s_apply_manifest

k8s_apply_manifest runs plain kubectl apply, which stores the whole object in the last-applied annotation, so any object over 256 KB fails (a ConfigMap holding a small static site was about 680 KB). We had to fall back to run_command with kubectl apply --server-side. Please add serverSide: true (and fieldManager / forceConflicts), keeping the same server dry run.

  1. CREATE A SECRET WITHOUT THE VALUE PASSING THROUGH THE AGENT

To create a Secret through MCP today, the value has to sit in the manifest the agent sends, so it ends up in the chat transcript. We created a cloudflared tunnel token Secret through run_command with stdin to avoid that. Please add k8s_create_secret(namespace, name, keys) where each key's value comes from somewhere the agent never sees: a Server Compass secret collection, a file on the server, or a value the user types in the desktop app. Return only key names and success.

NICE TO HAVE

  1. Restart the k3s / k3s-agent service on a node (the fix for the flannel case above), with the same tier as run_command.
  1. Join a new node: install k3s-agent on a Server Compass server with the join token read on the server side, never returned.
  1. Actual CPU and memory use per node and pod (kubectl top, from metrics-server), next to the requests k8s_overview already shows.

Roadmap progress

  1. PENDING

  2. REVIEWING

    —

  3. PLANNED

    —

  4. IN PROGRESS

    —

  5. COMPLETED

    —

  • — thanhlinh9191 submitted this request

Discussion0

Newest first
  • No comments yet. Add context or ask a question below.

Sign in to comment, vote and follow this request.

Sign in to reply