additional course material RH294
Olaf Bohlen
2020-08-20 1de6236f80a879ca110981fe0e5c0c05c521225b
hosts.j2
@@ -1,5 +1,4 @@
# template for /etc/hosts
{% for host in groups['all'] %}
{{ hostvars['host']['ansible_facts'] }}
{# {{ hostvars['host']['ansible_facts']['default_ipv4']['address'] }} {{ hostvars['host']['ansible_facts']['fqdn'] }} {{ hostvars['host']['ansible_facts']['hostname'] }} #}
{% endfor %}
{{ hostvars[host]['ansible_facts']['default_ipv4']['address'] }} {{ hostvars[host]['ansible_facts']['fqdn'] }} {{ hostvars[host]['ansible_facts']['hostname'] }}
{% endfor %}