Merge pull request #25495 from michalpalka/xen-forward-dns
xen service: Forward DNS queries from Xen guests
This commit is contained in:
commit
dc2fc5ed57
@ -100,6 +100,16 @@ in
|
|||||||
subnet.
|
subnet.
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
|
|
||||||
|
forwardDns = mkOption {
|
||||||
|
default = false;
|
||||||
|
description = ''
|
||||||
|
If set to <literal>true</literal>, the DNS queries from the
|
||||||
|
hosts connected to the bridge will be forwarded to the DNS
|
||||||
|
servers specified in /etc/resolv.conf .
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
virtualisation.xen.stored =
|
virtualisation.xen.stored =
|
||||||
@ -359,7 +369,6 @@ in
|
|||||||
interface=${cfg.bridge.name}
|
interface=${cfg.bridge.name}
|
||||||
except-interface=lo
|
except-interface=lo
|
||||||
bind-interfaces
|
bind-interfaces
|
||||||
auth-server=dns.xen.local,${cfg.bridge.name}
|
|
||||||
auth-zone=xen.local,$XEN_BRIDGE_NETWORK_ADDRESS/${toString cfg.bridge.prefixLength}
|
auth-zone=xen.local,$XEN_BRIDGE_NETWORK_ADDRESS/${toString cfg.bridge.prefixLength}
|
||||||
domain=xen.local
|
domain=xen.local
|
||||||
addn-hosts=/var/run/xen/dnsmasq.hostsfile
|
addn-hosts=/var/run/xen/dnsmasq.hostsfile
|
||||||
@ -367,8 +376,11 @@ in
|
|||||||
strict-order
|
strict-order
|
||||||
no-hosts
|
no-hosts
|
||||||
bogus-priv
|
bogus-priv
|
||||||
no-resolv
|
${optionalString (!cfg.bridge.forwardDns) ''
|
||||||
no-poll
|
no-resolv
|
||||||
|
no-poll
|
||||||
|
auth-server=dns.xen.local,${cfg.bridge.name}
|
||||||
|
''}
|
||||||
filterwin2k
|
filterwin2k
|
||||||
clear-on-reload
|
clear-on-reload
|
||||||
domain-needed
|
domain-needed
|
||||||
|
Loading…
x
Reference in New Issue
Block a user