ansible.vsphere_facts(3) - Linux man page

Name

vsphere_facts - Gather facts for a guest on VMWare vSphere

Description

This module gathers facts for a specific guest on VMWare vSphere. These facts include hardware and network related information useful for provisioning (e.g. macaddress, uuid).

This module requires the pysphere python module.

Options

host

The vSphere server from the cluster the virtual server is located on.(required)

password
The password to authenticate on the vSphere cluster.(required)
login

The login name to authenticate on the vSphere cluster.(required)

guest

The virtual server to gather facts for on the vSphere cluster.(required)."

Notes

This module ought to be run from a system that can access vSphere directly. Either by using local_action, or using delegate_to.

Examples

- local_action: vsphere_facts host=$esxserver login=$esxlogin password=$esxpassword guest=$inventory_hostname_short
  only_if: "'$cmdb_hwmodel'.startswith('VMWare ')

[{'hw_name': 'centos6', 'hw_processor_count': 1, 'hw_guest_id': 'rhel6_64Guest', 'hw_memtotal_mb': 2048, 'hw_eth0': [{'macaddress': '00:11:22:33:44:55', 'label': 'Network adapter 1', 'addresstype': 'assigned', 'summary': 'VLAN-321', 'macaddress_dash': '00-11-22-33-44-55'}], 'hw_product_uuid': 'ef50bac8-2845-40ff-81d9-675315501dac', 'hw_guest_full_name': 'Red Hat Enterprise Linux 6 (64-bit)'}]

Author

Dag Wieers

See Also

ansible(1), http://ansible.github.com/modules.html#vsphere-facts