Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Review:
* note on recommendation about use SA versus exciting (default) kubeconfig
* adding a collapsible section
* removed incorrect args

Signed-off-by: Matthias Wessendorf <[email protected]>
  • Loading branch information
matzew committed Oct 27, 2025
commit 1b80c250e6eb91cff8a782834391806be7047ed3
9 changes: 9 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,15 @@ If you're using the native binaries you don't need to have Node or Python instal

- Access to a Kubernetes cluster.

<details>
<summary><b>Claude Code</b></summary>

Follow the [dedicated Claude Code getting started guide](docs/GETTING_STARTED_CLAUDE_CODE.md) in our [user documentation](docs/).

For a secure production setup with dedicated ServiceAccount and read-only access, also review the [Kubernetes setup guide](docs/GETTING_STARTED_KUBERNETES.md).

</details>

### Claude Desktop

#### Using npx
Expand Down
18 changes: 4 additions & 14 deletions docs/GETTING_STARTED_CLAUDE_CODE.md
Original file line number Diff line number Diff line change
Expand Up @@ -88,20 +88,10 @@ to fetch and display the relevant information from your cluster:

Common command-line flags you can add to the `args` array:

| Flag | Description | Example |
|------|-------------|---------|
| `--read-only` | Enable read-only mode (recommended) | Already included above |
| `--kubeconfig <path>` | Path to kubeconfig file | Use `KUBECONFIG` env var instead |
| `--context <name>` | Use specific context from kubeconfig | `"--context", "my-cluster"` |
| `--namespace <ns>` | Default namespace for operations | `"--namespace", "production"` |

**Example with custom namespace:**

```bash
claude mcp add-json kubernetes-mcp-server \
'{"command":"npx","args":["-y","kubernetes-mcp-server@latest","--read-only","--namespace","production"],"env":{"KUBECONFIG":"'${HOME}'/.kube/mcp-viewer.kubeconfig"}}' \
-s user
```
| Flag | Description |
|------|-------------|
| `--read-only` | Enable read-only mode (recommended) |
| `--kubeconfig <path>` | Path to kubeconfig file (or use `KUBECONFIG` env var) |

## Next Steps

Expand Down
4 changes: 3 additions & 1 deletion docs/GETTING_STARTED_KUBERNETES.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,9 @@

This guide walks you through the foundational setup for using the Kubernetes MCP Server with your Kubernetes cluster. You'll create a dedicated, read-only ServiceAccount and generate a secure kubeconfig file that can be used with various MCP clients.

> **Note:** After completing this guide, continue with the [Claude Code CLI guide](GETTING_STARTED_CLAUDE_CODE.md). See the [docs README](README.md) for all available guides.
> **Note:** This setup is **recommended for production use** but not strictly required. The MCP Server can use your existing kubeconfig file (e.g., `~/.kube/config`), but using a dedicated ServiceAccount with limited permissions follows the principle of least privilege and is more secure.

> **Next:** After completing this guide, continue with the [Claude Code CLI guide](GETTING_STARTED_CLAUDE_CODE.md). See the [docs README](README.md) for all available guides.

## What You'll Create

Expand Down
Loading