-
Notifications
You must be signed in to change notification settings - Fork 3.3k
Description
Resource Provider
CRP
Description of Feature or Work Requested
User experience:
In text:
az vm create
-n MyVm
-g MyResourceGroup
--public-ip-address-dns-name MyUniqueDnsName
--image ubuntults
--size Standard_DS2_v2
--generate-ssh-keys
--data-disk-sizes-gb 10 20
--data-disk-delete-option 0=Detach 1=Delete /*Use a singular value to apply on all data disks, or use = to configure the delete behavior for individual disks
--os-disk-delete-option Delete
--nic-delete-option = /*Use a singular value to apply on all nics, or use = to configure the delete behavior for individual NICs
The new switches do the following
--nic-delete-behavior configures the deleteOption field for the NIC created for the VM
vm.properties.networkProfile.networkInterfaces[0].properties.deleteOption = "Delete"
--os-disk-delete-option Delete configures delete option for the OS Disk
cstorageProfile.dataDisks[*].osDisk= "Delete"
--data-disk-delete-option configures the delete option for data disks as specified
vm.properties.storageProfile.dataDisks[*].deleteOption = "Delete"
Swagger PR containing the deleteOption for VM NICs: Azure/azure-rest-api-specs#13449
Swagger PR for disk deleteOption: Azure/azure-rest-api-specs#13657
Minimum API Version Required
2021-03-01
Swagger Link
Target Date
5/25
