diff --git a/net/dns/manager_linux.go b/net/dns/manager_linux.go index c7884e5f5..b9d3477d8 100644 --- a/net/dns/manager_linux.go +++ b/net/dns/manager_linux.go @@ -23,6 +23,9 @@ func NewOSConfigurator(logf logger.Logf, interfaceName string) (OSConfigurator, if os.IsNotExist(err) { return newDirectManager() } + if err != nil { + return nil, fmt.Errorf("reading /etc/resolv.conf: %w", err) + } switch resolvOwner(bs) { case "systemd-resolved":