Loading...
Loading...
Manages scaling for GKE workloads using HPA and VPA. Use when configuring Horizontal Pod Autoscaler (HPA), configuring Vertical Pod Autoscaler (VPA), or applying best practices for GKE workload autoscaling. Do not use for cluster-level autoscaling (Cluster Autoscaler), static cluster sizing, or configuring node-level machine styles directly.
npx skill4agent add google/skills gke-workload-scalingkubectl scale deployment {deployment_name} --replicas={number} -n {namespace}
# Verify the scale event
kubectl get deployment {deployment_name} -n {namespace}kubectl autoscale deployment {deployment_name} --cpu-percent=50 --min=1 --max=10kubectl apply -f assets/hpa-example.yaml
# Verify HPA is created and fetching metrics
kubectl get hpagcloud container clusters update {cluster_name} --enable-vertical-pod-autoscaling --zone {zone}OffInitialAutoInPlaceOrRecreateAutominReplicasPodUpdatePolicyOffkubectl describe vpa {deployment_name}-vpa -n {namespace}targetrequestsnew_request = target * 1.2| Condition | Recommendation | Risk |
|---|---|---|
| CPU request >5x P95 actual | Reduce to | Medium |
| Memory request >3x P95 actual | Reduce to | Medium |
| CPU request >2x P95 actual | Rightsizing with 20% buffer | Low |
| No resource limits set | Add limits to prevent noisy-neighbor | Low |