Categories

Nov 5, 2019 in Ansible
Q: How can you access a list of Ansible_Variables?

1 Answer

Nov 5, 2019

Ansible gathers facts under machines under management. Further, these facts are accessed in Playbooks and in templates. One of the best ways to view a list of all the facts that are available in a machine, then you need to run the setup module in the ad-hoc way:

Ansible- m setup hostname

Once this statement is executed, it will print out a dictionary of all the facts that are available for that particular host. This is the best way to access the list of Ansible_variables.

Click here to read more about Ansible
Click here to read more about Insurance

Related questions

Madanswer
Oct 7 in Ansible
Feb 17 in Ansible
Jun 19 in Cloud Computing
...