Merge pull request #25 from smithtrevor/centos_support

Centos support
This commit is contained in:
Nate Riffe 2015-03-20 12:14:45 -05:00
commit 64aebc5173
5 changed files with 8 additions and 6 deletions

View File

@ -5,7 +5,7 @@ bind::params::bind_group: 'bind'
bind::params::bind_package: 'bind9'
bind::params::bind_service: 'bind9'
bind::params::nsupdate_package: 'dnsutils'
bind::namedconf: '/etc/bind/named.conf'
bind::confdir: '/etc/bind'
bind::cachedir: '/var/cache/bind'
bind::rndc: true

View File

@ -5,7 +5,7 @@ bind::params::bind_group: 'named'
bind::params::bind_package: 'bind'
bind::params::bind_service: 'named'
bind::params::nsupdate_package: 'bind-utils'
bind::namedconf: '/etc/named.conf'
bind::confdir: '/etc/named'
bind::cachedir: '/var/named'
bind::rndc: true

View File

@ -2,6 +2,7 @@
class bind (
$confdir = undef,
$namedconf = undef,
$cachedir = undef,
$forwarders = undef,
$dnssec = undef,
@ -9,7 +10,7 @@ class bind (
$rndc = undef,
$statistics_port = undef,
) {
include params
include ::bind::params
$auth_nxdomain = false
@ -59,7 +60,7 @@ class bind (
recurse => true,
}
file { "${confdir}/named.conf":
file { "${namedconf}":
content => template('bind/named.conf.erb'),
}

View File

@ -11,8 +11,8 @@ describe 'bind' do
})
}
it { should contain_file('_CONFDIR_/named.conf').that_requires('Package[bind]') }
it { should contain_file('_CONFDIR_/named.conf').that_notifies('Service[bind]') }
it { should contain_file('_NAMEDCONF_').that_requires('Package[bind]') }
it { should contain_file('_NAMEDCONF_').that_notifies('Service[bind]') }
it {
should contain_service('bind').with({

View File

@ -1,2 +1,3 @@
---
bind::confdir: '_CONFDIR_'
bind::namedconf: '_NAMEDCONF_'