{% for config in haproxy.routing.https %} {% for hostname in config.frontend %} {{ hostvars['bastion'].ansible_host }} {{ hostname }} {% endfor %} {% endfor %}