1 2 3 4 5 6 7 8 9- hosts: "{{ target | default('localhost') }}" connection: "{% if target != 'localhost' %}ssh{% else %}local{% endif %}" gather_facts: yes roles: - role: vm-automation
1 2 3 4 5 6 7 8 9
- hosts: "{{ target | default('localhost') }}" connection: "{% if target != 'localhost' %}ssh{% else %}local{% endif %}" gather_facts: yes roles: - role: vm-automation