mirror of
https://github.com/tldr-pages/tldr.git
synced 2025-08-30 13:13:42 +02:00

Co-authored-by: Managor <42655600+Managor@users.noreply.github.com> Co-authored-by: Dylan <145150333+dmmqz@users.noreply.github.com>
12 lines
572 B
Markdown
12 lines
572 B
Markdown
# kubectl autoscale
|
|
|
|
> Create an autoscaler to intelligently scale pod count based on kubernetes cluster demands.
|
|
> More information: <https://kubernetes.io/docs/reference/generated/kubectl/kubectl-commands#autoscale>.
|
|
|
|
- Auto scale a deployment with no target CPU utilization specified:
|
|
|
|
`kubectl autoscale {{[deploy|deployment]}} {{deployment_name}} --min={{min_replicas}} --max={{max_replicas}}`
|
|
|
|
- Auto scale a deployment with target CPU utilization:
|
|
|
|
`kubectl autoscale {{[deploy|deployment]}} {{deployment_name}} --max={{max_replicas}} --cpu-percent={{target_cpu}}`
|