mirror of
https://github.com/ansible-collections/community.general.git
synced 2026-05-07 22:02:50 +00:00
VMware: Add check mode support to module vmware_host_firewall_facts (#46265)
This commit is contained in:
committed by
Abhijeet Kasurde
parent
ab26119637
commit
a4961ff32a
@@ -80,3 +80,33 @@
|
||||
that:
|
||||
- "not firewall_0002_results.changed"
|
||||
- "firewall_0002_results.hosts_firewall_facts is defined"
|
||||
|
||||
- name: Gather firewall facts for all ESXi host from given cluster in check mode
|
||||
vmware_host_firewall_facts:
|
||||
hostname: "{{ vcsim }}"
|
||||
username: "{{ vcsim_instance.json.username }}"
|
||||
password: "{{ vcsim_instance.json.password }}"
|
||||
validate_certs: no
|
||||
cluster_name: "{{ ccr1 }}"
|
||||
register: firewall_0003_results
|
||||
check_mode: yes
|
||||
|
||||
- assert:
|
||||
that:
|
||||
- "not firewall_0003_results.changed"
|
||||
- "firewall_0003_results.hosts_firewall_facts is defined"
|
||||
|
||||
- name: Gather firewall facts for ESXi host in check mode
|
||||
vmware_host_firewall_facts:
|
||||
hostname: "{{ vcsim }}"
|
||||
username: "{{ vcsim_instance.json.username }}"
|
||||
password: "{{ vcsim_instance.json.password }}"
|
||||
validate_certs: no
|
||||
esxi_hostname: "{{ host1 }}"
|
||||
register: firewall_0004_results
|
||||
check_mode: yes
|
||||
|
||||
- assert:
|
||||
that:
|
||||
- "not firewall_0004_results.changed"
|
||||
- "firewall_0004_results.hosts_firewall_facts is defined"
|
||||
|
||||
Reference in New Issue
Block a user