Debian Codegraph @

ansible_collections/community/vmware/tests/integration/targets/vmware_cfg_backup/tasks/main.yml

raw
1 - import_role:
2 name: prepare_vmware_tests
3 vars:
4 setup_attach_host: true
5
6 - name: Save the ESXi configuration locally by authenticating against the vCenter and selecting the ESXi host
7 community.vmware.vmware_cfg_backup:
8 hostname: "{{ vcenter_hostname }}"
9 username: "{{ vcenter_username }}"
10 password: "{{ vcenter_password }}"
11 esxi_hostname: "{{ esxi1 }}"
12 dest: /tmp/
13 state: saved
14 register: cfg_backup_vcenter
15
16 - name: Ensure config was saved
17 assert:
18 that:
19 - cfg_backup_vcenter is changed
20
21 - name: Save the ESXi configuration locally directly from the ESXi host
22 community.vmware.vmware_cfg_backup:
23 hostname: "{{ esxi1 }}"
24 username: "{{ esxi1_username }}"
25 password: "{{ esxi1_password }}"
26 dest: /tmp/
27 state: saved
28 register: cfg_backup_esxi
29
30 - name: Ensure config was saved
31 assert:
32 that:
33 - cfg_backup_esxi is changed