list-resourcequotas
List Kubernetes resource quotas to monitor and manage namespace resource limits, ensuring cluster resource allocation compliance.
Instructions
List Kubernetes resource quotas in a namespace
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| namespace | No | The namespace to list resource quotas from (optional, defaults to current context namespace) |
Implementation Reference
- server.js:1991-1999 (handler)The handler function for the 'list-resourcequotas' tool. It constructs and executes a 'kubectl get resourcequotas' command with an optional namespace flag, then returns the command output as text content.case "list-resourcequotas": { const { namespace } = args || {}; const nsArg = namespace ? `-n ${namespace}` : ""; const cmd = `kubectl get resourcequotas ${nsArg} -o wide`; const { stdout } = await execAsync(cmd); return { content: [{ type: "text", text: stdout || "No resource quotas found" }] }; }
- server.js:916-927 (registration)The tool registration entry in the tools array, including name, description, and input schema. This is returned by the ListTools handler.name: "list-resourcequotas", description: "List Kubernetes resource quotas in a namespace", inputSchema: { type: "object", properties: { namespace: { type: "string", description: "The namespace to list resource quotas from (optional, defaults to current context namespace)" } } } },
- server.js:918-926 (schema)The input schema definition for the 'list-resourcequotas' tool, specifying an optional 'namespace' parameter.inputSchema: { type: "object", properties: { namespace: { type: "string", description: "The namespace to list resource quotas from (optional, defaults to current context namespace)" } } }