mirror of
https://github.com/ansible-collections/community.general.git
synced 2026-05-07 13:52:54 +00:00
Fix all VMware examples to use delegate_to (#43426)
Some users have problems using the VMware modules because they use the vCenter as target, and Ansible uses SSH to connect to the targets. Eventually we need to update the VMware guide to explain how the modules work, but the first fix is to update the examples. (We should backport to v2.6 and v2.5 too)
This commit is contained in:
committed by
Abhijeet Kasurde
parent
e96f90b440
commit
e2cac8cc93
@@ -53,24 +53,24 @@ extends_documentation_fragment: vmware.documentation
|
||||
EXAMPLES = '''
|
||||
# save the ESXi configuration locally by authenticating directly against the ESXi host
|
||||
- name: ESXI backup test
|
||||
local_action:
|
||||
module: vmware_cfg_backup
|
||||
hostname: esxi_hostname
|
||||
username: user
|
||||
password: pass
|
||||
state: saved
|
||||
dest: /tmp/
|
||||
vmware_cfg_backup:
|
||||
hostname: esxi_hostname
|
||||
username: user
|
||||
password: pass
|
||||
state: saved
|
||||
dest: /tmp/
|
||||
delegate_to: localhost
|
||||
|
||||
# save the ESXi configuration locally by authenticating against the vCenter and selecting the ESXi host
|
||||
- name: ESXI backup test
|
||||
local_action:
|
||||
module: vmware_cfg_backup
|
||||
hostname: vCenter
|
||||
esxi_hostname: esxi_hostname
|
||||
username: user
|
||||
password: pass
|
||||
state: saved
|
||||
dest: /tmp/
|
||||
vmware_cfg_backup:
|
||||
hostname: vCenter
|
||||
esxi_hostname: esxi_hostname
|
||||
username: user
|
||||
password: pass
|
||||
state: saved
|
||||
dest: /tmp/
|
||||
delegate_to: localhost
|
||||
'''
|
||||
|
||||
RETURN = '''
|
||||
|
||||
Reference in New Issue
Block a user