25 lines
722 B
YAML
25 lines
722 B
YAML
address: '%%domain_name_eth0'
|
|
addresses:
|
|
%if %%getVar('dns_client_address', None)
|
|
- dns_address: '%%dns_client_address'
|
|
dns_ip: '%%ip_dns'
|
|
%elif %%getVar('unbound_forward_address', None) is not None
|
|
%for %%authority in %%unbound_forward_address
|
|
- dns_address: %%authority
|
|
dns_ip: %%get_ip(%%str(%%authority))
|
|
%end for
|
|
%else
|
|
%for %%zone in %%nsd_zones
|
|
%set %%suffix = %%normalize_family(%%zone)
|
|
%set %%hostnames = %%nsd["nsd_zone_" + %%suffix]["hostname_" + %%suffix]["hostname_" + %%suffix]
|
|
%for %%nsd in %%hostnames
|
|
- dns_address: %%{nsd}.%%zone
|
|
dns_ip: %%nsd["ip_" + %%suffix]
|
|
%end for
|
|
%end for
|
|
%end if
|
|
%if %%dns_is_only_local
|
|
dns_is_only_local: true
|
|
%else
|
|
dns_is_only_local: false
|
|
%end if
|