Variables in Ansible can be defined in many different places, such as in inventory, in playbooks, in reusable files, in roles, and at the command-line. Ansible also allows to set variables directly in a task by using the set_fact module. Variables defined using the set_fact become associated with the host that the task is running […]
The post Ansible: Set Variable In Task appeared first on ShellHacks.