Add nodelocaldns only if it is enabled (#7731)
This commit is contained in:
parent
dfdebda0b6
commit
30d9882851
2 changed files with 2 additions and 2 deletions
|
@ -147,7 +147,7 @@
|
||||||
- name: generate nameservers to resolvconf
|
- name: generate nameservers to resolvconf
|
||||||
set_fact:
|
set_fact:
|
||||||
nameserverentries:
|
nameserverentries:
|
||||||
nameserver {{ ( coredns_server|d([]) + nameservers|d([]) + cloud_resolver|d([])) | unique | join(',nameserver ') }}
|
nameserver {{ ( ( [nodelocaldns_ip] if enable_nodelocaldns else []) + coredns_server|d([]) + nameservers|d([]) + cloud_resolver|d([])) | unique | join(',nameserver ') }}
|
||||||
supersede_nameserver:
|
supersede_nameserver:
|
||||||
supersede domain-name-servers {{ ( coredns_server|d([]) + nameservers|d([]) + cloud_resolver|d([])) | unique | join(', ') }};
|
supersede domain-name-servers {{ ( coredns_server|d([]) + nameservers|d([]) + cloud_resolver|d([])) | unique | join(', ') }};
|
||||||
|
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
[Resolve]
|
[Resolve]
|
||||||
DNS={{ coredns_server | list | join(' ') }}
|
DNS={{ (nodelocaldns_ip |default(coredns_server) )| list | join(' ') }}
|
||||||
FallbackDNS={{ ( nameservers|d([]) + cloud_resolver|d([])) | unique | join(' ') }}
|
FallbackDNS={{ ( nameservers|d([]) + cloud_resolver|d([])) | unique | join(' ') }}
|
||||||
Domains={{ ([ 'default.svc.' + dns_domain, 'svc.' + dns_domain ] + searchdomains|default([])) | join(' ') }}
|
Domains={{ ([ 'default.svc.' + dns_domain, 'svc.' + dns_domain ] + searchdomains|default([])) | join(' ') }}
|
||||||
#LLMNR=no
|
#LLMNR=no
|
||||||
|
|
Loading…
Reference in a new issue