Create a HorizontalPodAutoscaler for a deployment.

Section: Autoscaling

Create HPA

bash
bash
kubectl autoscale deployment web --cpu-percent=70 --min=2 --max=10 -n payments
Explanation

Create a HorizontalPodAutoscaler for a deployment.

Learn the surrounding workflow

Compare similar commands or jump into common fixes when this command is part of a bigger troubleshooting path.

Related commands

Same sheet · prioritizing Autoscaling
List HPAs
Show HorizontalPodAutoscalers.
OpenIn sheetbashsame section
Describe HPA
Inspect metrics, thresholds, and scaling recommendations.
OpenIn sheetbashsame section
Scale replicaset
Directly scale a ReplicaSet when needed.
OpenIn sheetbashsame section
List replicasets
Show ReplicaSets created by Deployments.
OpenIn sheetbashsame section
Describe replicaset
Inspect pod template and controller ownership.
OpenIn sheetbashsame section
List deployments
Show deployments across namespaces.