get_pod_logs
Retrieve Kubernetes pod logs from a specific cluster and namespace, with configurable tail lines to aid troubleshooting and monitoring.
Instructions
获取指定 pod 的日志。
Args:
cluster: 目标集群,可选 "local"(本地 k3s)或 "cloud"(阿里云 k3s),默认 "local"
namespace: 指定的 namespace,默认 "default"
pod_name: 指定的 pod 名称
tail_lines: 返回最后多少行日志,默认 100
Tool call template
This tool declares no required parameters. Add optional parameters from the input schema as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {},
"name": "get_pod_logs"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| cluster | No | local | |
| pod_name | No | ||
| namespace | No | default | |
| tail_lines | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |