diff --git a/roles/nagios_server/templates/nagios/hosts/cloud-hosts.cfg.j2 b/roles/nagios_server/templates/nagios/hosts/cloud-hosts.cfg.j2 index aa06d067e5..8ea2d502a5 100644 --- a/roles/nagios_server/templates/nagios/hosts/cloud-hosts.cfg.j2 +++ b/roles/nagios_server/templates/nagios/hosts/cloud-hosts.cfg.j2 @@ -16,7 +16,7 @@ define host { {% 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 %} +{% if hostvars[host].ansible_default_ipv4.address is defined and not in groups['cloud'] %} address {{ hostvars[host].ansible_default_ipv4.address }} {% endif %} {% else %}