azure_rm_virtualmachine : fix support for existing machines provisioned with a managed image (#32984)
This commit is contained in:
parent
d5cbb53f5a
commit
390a08c781
1 changed files with 2 additions and 0 deletions
|
@ -1127,6 +1127,8 @@ class AzureRMVirtualMachine(AzureRMModuleBase):
|
|||
disk_size_gb=vm_dict['properties']['storageProfile']['osDisk']['diskSizeGB']
|
||||
),
|
||||
image_reference=self.compute_models.ImageReference(
|
||||
id=vm_dict['properties']['storageProfile']['imageReference']['id'],
|
||||
) if 'id' in vm_dict['properties']['storageProfile']['imageReference'].keys() else self.compute_models.ImageReference(
|
||||
publisher=vm_dict['properties']['storageProfile']['imageReference']['publisher'],
|
||||
offer=vm_dict['properties']['storageProfile']['imageReference']['offer'],
|
||||
sku=vm_dict['properties']['storageProfile']['imageReference']['sku'],
|
||||
|
|
Loading…
Reference in a new issue