Gather current host information, which is the underlying implementation of gather_facts in playbooks.
No additional parameters.
1. Enable gather_facts in playbook
- name: playbook
hosts: localhost
gather_facts: true2. Explicitly call setup in task
- name: setup
setup: {}