create_hpa
Create a Horizontal Pod Autoscaler to automatically scale Deployments or DeploymentConfigs based on target CPU utilization, with configurable min and max replicas.
Instructions
Create an HPA using 'oc autoscale'. target_ref format: 'Deployment/my-app' or 'DeploymentConfig/my-dc'. cpu_percent: target CPU utilisation percentage (default 80).
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"name": "<name>",
"namespace": "<namespace>",
"target_ref": "<target_ref>",
"min_replicas": "<min_replicas>",
"max_replicas": "<max_replicas>"
},
"name": "create_hpa"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| name | Yes | ||
| cluster | No | ||
| namespace | Yes | ||
| target_ref | Yes | ||
| cpu_percent | No | ||
| max_replicas | Yes | ||
| min_replicas | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |