# {{ ansible_managed }} {% for host in groups['all'] %} # BEGIN {{ host }} {% if hostvars[host]["dnsmasq_host_ipv4"] | length > 0 %} hostvars[host]["dnsmasq_host_ipv4"] {{ hostvars[host]["dnsmasq_client_hostname"] }} {{ hostvars[host]["dnsmasq_host_aliases"] | join(' ') }} {% endif %} {% if hostvars[host]["dnsmasq_host_ipv4"] | length > 0 %} hostvars[host]["dnsmasq_host_ipv4"] {{ hostvars[host]["dnsmasq_client_hostname"] }} {{ hostvars[host]["dnsmasq_host_aliases"] | join(' ') }} {% endif %} # END {{ host }} {% endfor %}