[AKS] Mixed sku autoscaling support for VMs agentpool#9808
[AKS] Mixed sku autoscaling support for VMs agentpool#9808reneeli123 wants to merge 6 commits intoAzure:mainfrom
Conversation
|
| rule | cmd_name | rule_message | suggest_message |
|---|---|---|---|
| aks nodepool auto-scale | sub group aks nodepool auto-scale added |
|
Hi @reneeli123, |
|
Thank you for your contribution! We will review the pull request and get back to you soon. |
|
The git hooks are available for azure-cli and azure-cli-extensions repos. They could help you run required checks before creating the PR. Please sync the latest code with latest dev branch (for azure-cli) or main branch (for azure-cli-extensions). pip install azdev --upgrade
azdev setup -c <your azure-cli repo path> -r <your azure-cli-extensions repo path>
|
CodeGen Tools Feedback CollectionThank you for using our CodeGen tool. We value your feedback, and we would like to know how we can improve our product. Please take a few minutes to fill our codegen survey |
|
There was a problem hiding this comment.
Pull request overview
Adds mixed-SKU autoscaling management for AKS VirtualMachines agentpools by introducing explicit CLI subcommands to manage individual virtualMachinesProfile.scale.autoscale profiles, and updates existing autoscaler update behavior/docs accordingly.
Changes:
- Introduces
az aks nodepool auto-scale {add,update,delete}commands wired into command table, params, and help. - Updates VMs agentpool autoscaler enable/disable behavior to convert between manual and autoscale profiles (supporting multiple profiles).
- Extends scenario coverage for the new auto-scale commands and conversions.
Reviewed changes
Copilot reviewed 6 out of 7 changed files in this pull request and generated 6 comments.
Show a summary per file
| File | Description |
|---|---|
| src/aks-preview/azext_aks_preview/custom.py | Implements add/update/delete operations for autoscale profiles on VMs agentpools. |
| src/aks-preview/azext_aks_preview/commands.py | Registers the new aks nodepool auto-scale command group. |
| src/aks-preview/azext_aks_preview/_params.py | Adds argument contexts for the new auto-scale subcommands. |
| src/aks-preview/azext_aks_preview/_help.py | Documents new auto-scale commands and clarifies autoscaler flags for VMs pools. |
| src/aks-preview/azext_aks_preview/agentpool_decorator.py | Adjusts VMs autoscaler update/convert logic and blocks --update-cluster-autoscaler for VMs pools. |
| src/aks-preview/azext_aks_preview/tests/latest/test_aks_commands.py | Adds scenario steps for auto-scale update/add/delete and manual<->auto conversions. |
| '--update-cluster-autoscaler ' \ | ||
| '--min-count 1 --max-count 5' | ||
| self.cmd(update_nodepool_cmd, checks=[ | ||
| # update an existing autoscale profile using auto-scale update |
There was a problem hiding this comment.
Added feature header and requeue: https://dev.azure.com/msazure/CloudNativeCompute/_build/results?buildId=161604792&view=results
There was a problem hiding this comment.
seems like it failed with a transient error, re-queued live test
There was a problem hiding this comment.
Still failing due to the feature header, added it to all commands and requeued: https://dev.azure.com/msazure/CloudNativeCompute/_build/results?buildId=161656179&view=results
94ffa5e to
654afe5
Compare
Co-authored-by: Copilot <copilot@github.com>
654afe5 to
8d22b98
Compare
This checklist is used to make sure that common guidelines for a pull request are followed.
Related command
Create an AKS cluster with Virtual Machines node pool - Autoscale mode:
az aks create
--resource-group myResourceGroup
--name myAKSCluster
--vm-set-type "VirtualMachines"
--node-vm-size "Standard_D4s_v3"
--enable-cluster-autoscaler
--min-count 2
--max-count 5
Add an autoscaled Virtual Machines node pool to an existing cluster:
az aks nodepool add
--resource-group myResourceGroup
--cluster-name myAKSCluster
--name myvmpool
--vm-set-type "VirtualMachines"
--node-vm-size "Standard_D4s_v3"
--enable-cluster-autoscaler
--min-count 2
--max-count 5
Switch from manual to auto mode (converts all manual scale profiles to autoscale profiles with the same min/max):
az aks nodepool update
--resource-group myResourceGroup
--cluster-name myAKSCluster
--name myvmpool
--enable-cluster-autoscaler
--min-count 2
--max-count 5
Switch from auto to manual mode (converts all autoscale profiles back to manual scale profiles defaulting node count to minCount):
az aks nodepool update
--resource-group myResourceGroup
--cluster-name myAKSCluster
--name myvmpool
--disable-cluster-autoscaler
Add an autoscale profile to an existing VMS pool:
az aks nodepool auto-scale add
--resource-group myResourceGroup
--cluster-name myAKSCluster
--name myvmpool
--node-vm-size "Standard_D2s_v3"
--min-count 3
--max-count 5
Update an existing autoscale profile (change VM size and/or min/max count):
az aks nodepool auto-scale update
--resource-group myResourceGroup
--cluster-name myAKSCluster
--name myvmpool
--current-node-vm-size "Standard_D2s_v3"
--node-vm-size "Standard_D8s_v3"
--min-count 2
--max-count 4
Delete an existing autoscale profile:
az aks nodepool auto-scale delete
--resource-group myResourceGroup
--cluster-name myAKSCluster
--name myvmpool
--current-node-vm-size "Standard_D2s_v3"
General Guidelines
azdev style <YOUR_EXT>locally? (pip install azdevrequired)python scripts/ci/test_index.py -qlocally? (pip install wheel==0.30.0required)For new extensions:
About Extension Publish
There is a pipeline to automatically build, upload and publish extension wheels.
Once your pull request is merged into main branch, a new pull request will be created to update
src/index.jsonautomatically.You only need to update the version information in file setup.py and historical information in file HISTORY.rst in your PR but do not modify
src/index.json.