Comment 9 for bug 1843634

Revision history for this message
Ryan Harper (raharper) wrote :

@Nathan, definitely an improvement, I'll update my merge proposal.

@Scott

For statically configured DNS settings, writting to /etc/resolv.conf is functional but not optimal on SUSE; doing so disables the netconfig automatic management. As an improvement, cloud-init should look to write these values as NETCONFIG_ variables in /etc/sysconfig/network/config

https://doc.opensuse.org/documentation/leap/reference/html/book.opensuse.reference/cha.network.html#sec.network.manconf.files.resolv

In the case for DHCP, our current policy allows static DNS (we've also called it "global" dns settings, per type:nameserver in v1 config) to apply to any interface that has static ip configuration but no explicit nameserver/search settings. Interfaces with DHCP do not get the "global" dns settings applied.

We've room for improvement in netplan (v2) where there are explicit DNS overrides for DHCP:

https://github.com/CanonicalLtd/netplan/blob/master/doc/netplan.md#dhcp-overrides