Skip to content

Commit d3e6745

Browse files
committed
updated documentation
1 parent 696820a commit d3e6745

File tree

1 file changed

+0
-91
lines changed

1 file changed

+0
-91
lines changed

docs/AUTH_HEADERS_PROVIDER.md

Lines changed: 0 additions & 91 deletions
Original file line numberDiff line numberDiff line change
@@ -175,94 +175,3 @@ client := NewMCPClient(
175175
})
176176
)
177177
```
178-
179-
### Using Claude Desktop
180-
181-
```json
182-
{
183-
"mcpServers": {
184-
"kubernetes": {
185-
"url": "https://mcp-server.example.com/sse",
186-
"headers": {
187-
"kubernetes-server": "https://k8s.example.com:6443",
188-
"kubernetes-certificate-authority-data": "LS0tLS1CRUdJTi...",
189-
"kubernetes-authorization": "Bearer YOUR_KUBERNETES_TOKEN"
190-
}
191-
}
192-
}
193-
}
194-
```
195-
196-
### Using Client Certificates
197-
198-
```json
199-
{
200-
"mcpServers": {
201-
"kubernetes": {
202-
"url": "https://mcp-server.example.com/sse",
203-
"headers": {
204-
"kubernetes-server": "https://k8s.example.com:6443",
205-
"kubernetes-certificate-authority-data": "LS0tLS1CRUdJTi...",
206-
"kubernetes-client-certificate-data": "LS0tLS1CRUdJTi...",
207-
"kubernetes-client-key-data": "LS0tLS1CRUdJTi..."
208-
}
209-
}
210-
}
211-
}
212-
```
213-
214-
### Using cURL
215-
216-
```bash
217-
# With bearer token
218-
curl -X POST https://mcp-server.example.com/mcp \
219-
-H "Content-Type: application/json" \
220-
-H "kubernetes-server: https://k8s.example.com:6443" \
221-
-H "kubernetes-certificate-authority-data: LS0tLS1CRUdJTi..." \
222-
-H "kubernetes-authorization: Bearer eyJhbGci..." \
223-
-d '{
224-
"jsonrpc": "2.0",
225-
"method": "tools/call",
226-
"params": {
227-
"name": "pods_list",
228-
"arguments": {"namespace": "default"}
229-
},
230-
"id": 1
231-
}'
232-
```
233-
234-
### Getting Required Values
235-
236-
#### 1. Kubernetes Server URL
237-
238-
```bash
239-
kubectl config view --minify -o jsonpath='{.clusters[0].cluster.server}'
240-
```
241-
242-
#### 2. CA Certificate (base64)
243-
244-
```bash
245-
kubectl config view --minify --raw -o jsonpath='{.clusters[0].cluster.certificate-authority-data}'
246-
```
247-
248-
#### 3. Bearer Token
249-
250-
```bash
251-
# From current context
252-
kubectl config view --minify --raw -o jsonpath='{.users[0].user.token}'
253-
254-
# Or get a service account token
255-
kubectl create token <service-account-name> -n <namespace>
256-
```
257-
258-
#### 4. Client Certificate (base64)
259-
260-
```bash
261-
kubectl config view --minify --raw -o jsonpath='{.users[0].user.client-certificate-data}'
262-
```
263-
264-
#### 5. Client Key (base64)
265-
266-
```bash
267-
kubectl config view --minify --raw -o jsonpath='{.users[0].user.client-key-data}'
268-
```

0 commit comments

Comments
 (0)