# Building a Simple MCP Server for KubeDesk (Open-Source Kubernetes GUI)

DevFeed: [Building a Simple MCP Server for KubeDesk (Open-Source Kubernetes GUI)](<https://devfeed.tech/articles/building-a-simple-mcp-server-for-kubedesk-open-source-kubernetes-gui-109720.md>)

Original publisher: [Read original article](<https://blog.devops.dev/a-simple-mcp-server-implementation-example-with-open-source-kubernetes-management-gui-kubedesk-b73a80e2144e?source=rss----33f8b2d9a328---4>)

Author: Yasar Gozudeli

Published: 2026-10-30T18:59:53Z

Content type: tutorial

Language: en

Sources: [DevOps.dev](<https://devfeed.tech/sources/devops-dev.md>)

Topics: [MSP MCP](<https://devfeed.tech/topics/msp-mcp.md>), [Remote Procedure Call (RPC)](<https://devfeed.tech/topics/rpc.md>), [rancher](<https://devfeed.tech/topics/rancher.md>), [Claude Code](<https://devfeed.tech/topics/claude-code.md>), [Open Source](<https://devfeed.tech/topics/open-source.md>)

Tags: [adapter](<https://devfeed.tech/tags/adapter.md>), [agent](<https://devfeed.tech/tags/agent.md>), [coding-agents](<https://devfeed.tech/tags/coding-agents.md>), [desktop-app](<https://devfeed.tech/tags/desktop-app.md>), [devops](<https://devfeed.tech/tags/devops.md>), [experimental](<https://devfeed.tech/tags/experimental.md>), [generative-ai-tools](<https://devfeed.tech/tags/generative-ai-tools.md>), [gui](<https://devfeed.tech/tags/gui.md>), [implementation](<https://devfeed.tech/tags/implementation.md>), [java](<https://devfeed.tech/tags/java.md>), [kubectl](<https://devfeed.tech/tags/kubectl.md>), [kubernetes](<https://devfeed.tech/tags/kubernetes.md>), [mcp](<https://devfeed.tech/tags/mcp.md>), [mcp-protocol](<https://devfeed.tech/tags/mcp-protocol.md>), [mcp-server](<https://devfeed.tech/tags/mcp-server.md>), [model-context-protocol](<https://devfeed.tech/tags/model-context-protocol.md>), [open-source](<https://devfeed.tech/tags/open-source.md>), [pods](<https://devfeed.tech/tags/pods.md>), [server](<https://devfeed.tech/tags/server.md>), [simple](<https://devfeed.tech/tags/simple.md>)

## AI overview

The guide shows how to add a small, read-only MCP server to KubeDesk as an adapter over its existing ClusterService, letting coding agents inspect Kubernetes through the app's service layer. It uses the JDK HTTP server and Jackson already on the classpath, exposes tools for health scans and resource inspection, and documents a Streamable HTTP example using the 2025-11-25 protocol flow; the text notes that later revisions require their own transport rules. It recommends server-side filtering, compact and capped results, stable context and namespace defaults, argument validation, timeouts, bounded resource use, and actionable tool errors. Loopback binding alone does not secure local read access: Origin checks, an authentication decision, Kubernetes RBAC, and careful handling of sensitive logs and manifests matter. The first version omits write tools and remote access; a CLI can offer similar controls, while MCP provides a standard interface for compatible clients.

## Source excerpt

A practical guide to exposing an existing Java application through the Model Context Protocol, with no new framework and a deliberately small set of read-only tools. KubeDesk is a lightweight, open source desktop GUI for Kubernetes, a kind of kubectl without the terminal. In this article I am going to explain how an experimental, read-only MCP server implemented in the project.KubeDesk MCP Server panel How a devops engineer normally work with kubectl, or any other kubernetes management tool? they check some information in the cluster, sometimes in pods, sometimes in some other kubernetes item and then they copy some information to LLM Chat screen, and then LLM either ask them some additional information or gives some code to execute and the loop goes on. How it would be if an agent could directly connect to kubernetes management tool and use it under a human survalience? So in this article I am going to tell you how it can be implemented so that developers can have a basic idea of what is MCP from end to end and see it is in action. 1. The misconception to clear first When I described the idea, the first question might be: "Why do I even need a server? Can't the agent just call KubeDesk's code directly?" "KubeDesk is already a tool working on my desktop -- isn't this tools-of-a-tool(my local coding agent can call the source code) already?" The useful distinction is between the model deciding what to do and the application executing it. For this implementation, there is one MCP connection: Host = the application running the agent loop, such as Codex or Claude Code. It talks to the model and manages tool execution; the model itself may run remotely. Client = the MCP component inside that application running the agent loop. It discovers tools and sends tool calls. Server = the program exposing those tools and executing them. In KubeDesk, it is an adapter with no LLM of its own. That is our design choice, not a restriction imposed by MCP. Coding agents such as Codex and