{Compute} az vmss reimage: Migrate command to aaz-based implementation#32834
{Compute} az vmss reimage: Migrate command to aaz-based implementation#32834
az vmss reimage: Migrate command to aaz-based implementation#32834Conversation
️✔️AzureCLI-FullTest
|
️✔️AzureCLI-BreakingChangeTest
|
|
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>
|
There was a problem hiding this comment.
Pull request overview
This PR migrates the az vmss reimage command from the legacy mgmt.compute SDK to the modern AAZ (Azure CLI Auto-generated) framework. The migration updates the implementation to use declarative AAZ command classes while preserving all existing functionality and behavior.
Changes:
- Migrated
reimage_vmssfunction from SDK-based to AAZ-based implementation - Removed
min_apiconstraint from command registration (AAZ handles API versioning internally) - Added two new AAZ command files:
_reimage.pyand_reimageall.py
Reviewed changes
Copilot reviewed 5 out of 5 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| src/azure-cli/azure/cli/command_modules/vm/custom.py | Refactored reimage_vmss to use AAZ commands (VmssReimage and VmssReimageAll) instead of SDK client methods |
| src/azure-cli/azure/cli/command_modules/vm/commands.py | Moved command registration to AAZ-compatible command group and removed SDK-specific min_api constraint |
| src/azure-cli/azure/cli/command_modules/vm/aaz/latest/vmss/_reimage.py | New auto-generated AAZ command for OS disk reimage operation |
| src/azure-cli/azure/cli/command_modules/vm/aaz/latest/vmss/_reimageall.py | New auto-generated AAZ command for all disks (OS + data) reimage operation |
| src/azure-cli/azure/cli/command_modules/vm/aaz/latest/vmss/init.py | Added exports for new AAZ command modules |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Related command
az vmss reimageDescription
Migration from mgmt.compute to aaz-based
aaz Azure/aaz#946
Testing Guide
History Notes
This checklist is used to make sure that common guidelines for a pull request are followed.
The PR title and description has followed the guideline in Submitting Pull Requests.
I adhere to the Command Guidelines.
I adhere to the Error Handling Guidelines.