searchpaths << "debian.org"
-if nameservers.empty?
- raise Puppet::ParseError, "Something has gone wrong writing resolv.conf: probably included for wrong hoster"
-end
-
resolvconf = ''
resolvconf += "search " + searchpaths.join(" ") + "\n"
if runs_local_resolver
resolvconf += "nameserver 127.0.0.1\n"
else
+ if nameservers.empty?
+ raise Puppet::ParseError, "Something has gone wrong writing resolv.conf. No nameservers to use!"
+ end
+
nameservers.each do |ns|
resolvconf += "nameserver " + ns + "\n"
end