diff --git a/NEWS b/NEWS index f7578e066e95aabf92f8ff70c3f7e344ff05e496..f6a3957188e93561ad8c858748586610d791decd 100644 --- a/NEWS +++ b/NEWS @@ -1,5 +1,8 @@ unreleased (??) + [dns] Make dns_cache a class-level parameter, so that it can be set in + Hiera (as base::dns::dns_cache) (akkornel) + [dns] Add support for Livermore, via Hiera. Set base::dns::livermore (in Hiera) to true, and Livermore DNS gets added to resolv.conf (akkornel) diff --git a/manifests/dns.pp b/manifests/dns.pp index 8c8b7a1ce7e4dcfe2ffae57f366fab58913249c0..aee19e83af8dc387a8b0dfce08562ef4128c11de 100644 --- a/manifests/dns.pp +++ b/manifests/dns.pp @@ -4,15 +4,21 @@ # resolv.conf file. This is helpful in DHCP environments. # To enable, use Hiera to set base::dns::no_resolv_conf to "true". +# If you use a DNS cache, you can change base::dns::dns_cache in Hiera to true, +# and 127.0.0.1 will be set as the first nameserver. + # For Livermore sites, change base::dns::livermore to true, and the Livermore -# DNS server will be added above the standard DNS servers. +# DNS server will be added above the standard DNS servers. If dns_cache is +# also true, Livermore DNS will be second (right below 127.0.0.1). class base::dns( $no_resolv_conf = false, + $dns_cache = 'NONE', $livermore = false, ) { if !$no_resolv_conf { base::dns::resolv_conf { $::fqdn_lc: ensure => present, + dns_cache => $dns_cache, livermore => $livermore, } }