Skip to main content
Glama
README.md
# k8s-mcp-assistant

A **read-only Kubernetes MCP (Model Context Protocol) server** to help developers quickly inspect the state of their apps in a dev cluster — without giving them full `kubectl` access.

Built for teams where only Cloud/SRE has cluster access, but developers still need answers like:
- “Why is my app in `CrashLoopBackOff`?”
- “What do the pod events say?”
- “Show me the container logs (including `--previous`)”

---

## What it does

This MCP exposes safe, **read-only tools** that fetch Kubernetes status and logs from a cluster using a restricted kubeconfig / ServiceAccount.

### Tools

- **`k8s.app_status`**
  - Shows a high-level view of an app (deploy/pods readiness, restarts, basic diagnostics)
- **`k8s.pod_logs`**
  - Fetches pod logs with practical options like `tail`, `since`, `timestamps`, `container`, and `previous`

> ⚠️ This project is intentionally **read-only**: no `apply`, no `delete`, no `exec`, no port-forward, no secret retrieval.

---

## Quickstart (local)

### 1) Clone & install
```bash
git clone https://github.com/nicolasmosquerar/k8s-mcp-assistant.git
cd k8s-mcp-assistant
npm install
npm run build


**Made with ❤️ for safer Kubernetes debugging**

TDQS

B3.1/5.0

Scored across 2 tools

Disambiguation5/5

The two tools have clearly distinct purposes: one checks pod status for an application, while the other retrieves logs for a specific pod. There is no overlap or ambiguity between these functions, making it easy for an agent to select the correct tool.

Naming Consistency5/5

Both tools follow a consistent naming pattern using 'k8s.' prefix and snake_case (app_status, pod_logs). This uniformity enhances readability and predictability across the tool set.

Tool Count2/5

With only two tools, the server feels thin for a Kubernetes assistant domain, which typically involves more operations like scaling, deployment, or resource management. This limited scope may hinder agent workflows.

Completeness2/5

The tool set is severely incomplete for Kubernetes operations, lacking essential CRUD actions such as creating, updating, or deleting resources. Agents will face significant gaps when trying to perform common tasks in this domain.

Maintenance

ActivityInactive
ResponsivenessNo issues