Revert "Revert "just use the hostname as the address here, because aws is weird with networking""

This reverts commit cecefbe1206479326f3b579bafef971532ac92bf.
This commit is contained in:
Rick Elrod 2020-02-06 19:21:43 +00:00 committed by Pierre-Yves Chibon
parent db023609f6
commit cdc6091079

View file

@ -13,15 +13,7 @@ define host {
{% else %}
alias {{ host }}
{% endif %}
{% if hostvars[host].eth0_ip is defined %}
address {{ hostvars[host].eth0_ip }}
{% elif hostvars[host].ansible_default_ipv4 is defined %}
{% if hostvars[host].ansible_default_ipv4.address is defined %}
address {{ hostvars[host].ansible_default_ipv4.address }}
{% endif %}
{% else %}
address {{ host }}
{% endif %}
}
{% endif %}
{% endfor %}