## ### THIS FILE IS UNDER PUPPET CONTROL. DON'T EDIT IT HERE. ### USE: git clone git+ssh://$USER@puppet.debian.org/srv/puppet.debian.org/git/dsa-puppet.git ### <%= nameservers = [] searchpaths = [] options = [] if %w{draghi liszt widor spohr samosa}.include?(hostname) nameservers << "127.0.0.1" end nameservers += hosterinfo['nameservers'] if hosterinfo['nameservers'] searchpaths += hosterinfo['searchpaths'] if hosterinfo['searchpaths'] options += hosterinfo['resolvoptions'] if hosterinfo['resolvoptions'] 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 nameservers.each do |ns| resolvconf += "nameserver " + ns + "\n" end end options.each do |opt| resolvconf += "options " + opt + "\n" end resolvconf %>