mirror of
https://github.com/ansible-collections/community.general.git
synced 2026-05-06 13:22:48 +00:00
Update azure_rm_managed_disk.py --add zones (#53788)
This commit is contained in:
@@ -11,6 +11,7 @@
|
||||
state: absent
|
||||
with_items:
|
||||
- "md{{ rpfx }}os"
|
||||
- "md{{ rpfx }}3"
|
||||
- "md{{ rpfx }}2"
|
||||
- "md{{ rpfx }}1"
|
||||
|
||||
@@ -64,6 +65,24 @@
|
||||
- output.state.os_type == None
|
||||
- output.state.storage_account_type == "Standard_LRS"
|
||||
|
||||
- name: Create new managed disk with zone
|
||||
azure_rm_managed_disk:
|
||||
resource_group: "{{ resource_group }}"
|
||||
name: "md{{ rpfx }}3"
|
||||
storage_account_type: "Standard_LRS"
|
||||
disk_size_gb: 1
|
||||
zone: 1
|
||||
tags:
|
||||
testing: testing
|
||||
delete: never
|
||||
register: output
|
||||
|
||||
- name: Assert status succeeded and results include an zone value
|
||||
assert:
|
||||
that:
|
||||
- output.changed
|
||||
- output.state.zone == ["1"]
|
||||
|
||||
- name: Change the operating system type of the managed disk to linux
|
||||
azure_rm_managed_disk:
|
||||
resource_group: "{{ resource_group }}"
|
||||
@@ -487,6 +506,7 @@
|
||||
with_items:
|
||||
- 1
|
||||
- 2
|
||||
- 3
|
||||
|
||||
- name: Delete virtual machine
|
||||
azure_rm_virtualmachine:
|
||||
|
||||
Reference in New Issue
Block a user