The vmware_host_facts module

As you may have guessed, this module gathers facts about the VMware ESXi hosts within your vSphere or vCenter cluster:

- name: Find out facts on the esxi hosts  vmware_host_facts:    hostname: "{{ vsphere_host }}"    username: "{{ vsphere_username }}"    password: "{{ vsphere_password }}"    validate_certs: "no"  register: host_facts  delegate_to: localhost

Get Learn Ansible now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.