dns/master: Add support for slaves as IPs (slaves_ip)

dehydrated
Felix Stupp 4 years ago
parent 2b0e2f4803
commit 7c9f135da5
Signed by: zocker
GPG Key ID: 93E1BD26F6B02FB7

@ -23,5 +23,6 @@ expire: 3600000
ttl: "{{ global_dns_ttl }}"
slaves: [] # for retriving IPs automatically by Ansible
slaves_ip: []
dname_subdomain: "external" # Must not contain the base domain, can be used to allow ignoring local overrides on purpose, will be ignored if empty

@ -36,11 +36,17 @@ zone "{{ domain }}" {
{{ hostvars[fqdn].ansible_default_ipv4.address }};
{{ hostvars[fqdn].ansible_default_ipv6.address }};
{% endfor %}
{% for ip in slaves_ip %}
{{ ip }};
{% endfor %}
};
also-notify {
{% for fqdn in slaves %}
{{ hostvars[fqdn].ansible_default_ipv4.address }};
{{ hostvars[fqdn].ansible_default_ipv6.address }};
{% endfor %}
{% for ip in slaves_ip %}
{{ ip }};
{% endfor %}
};
};

Loading…
Cancel
Save