aboutsummaryrefslogtreecommitdiffstats
path: root/modules/bind/manifests
diff options
context:
space:
mode:
authorMichael Scherer <misc@mageia.org>2010-10-26 23:54:17 +0000
committerMichael Scherer <misc@mageia.org>2010-10-26 23:54:17 +0000
commit534bd4a17766186f23f577668da7639f3dad4ffd (patch)
tree4a6220f044d01e6145bfef19e3cc61b6bac3a2cf /modules/bind/manifests
parent7c39256faf11eb5a8a57915a0409b0c759ca70d2 (diff)
downloadpuppet-534bd4a17766186f23f577668da7639f3dad4ffd.tar
puppet-534bd4a17766186f23f577668da7639f3dad4ffd.tar.gz
puppet-534bd4a17766186f23f577668da7639f3dad4ffd.tar.bz2
puppet-534bd4a17766186f23f577668da7639f3dad4ffd.tar.xz
puppet-534bd4a17766186f23f577668da7639f3dad4ffd.zip
- add bind module
Diffstat (limited to 'modules/bind/manifests')
-rw-r--r--modules/bind/manifests/init.pp45
1 files changed, 45 insertions, 0 deletions
diff --git a/modules/bind/manifests/init.pp b/modules/bind/manifests/init.pp
new file mode 100644
index 00000000..38716b9d
--- /dev/null
+++ b/modules/bind/manifests/init.pp
@@ -0,0 +1,45 @@
+package { bind:
+ ensure => installed
+}
+
+service { named:
+ ensure => running,
+ path => "/etc/init.d/named",
+ subscribe => [ Package["bind"]]
+}
+
+file { '/etc/named.conf':
+ ensure => present,
+ owner => root,
+ group => root,
+ mode => 644,
+ require => Package["bind"],
+ content => "",
+ notify => [Service['named']]
+}
+
+define zone_master {
+ file { "/var/lib/named/var/named/master/$name.zone":
+ ensure => present,
+ owner => root,
+ group => root,
+ mode => 644,
+ content => template("bind/zones/$name.zone"),
+ require => Package[bind],
+ notify => Service[named]
+ }
+}
+
+class bind_master inherits bind_base {
+ file { '/etc/named.conf':
+ content => template("bind/named_base.conf", "bind/named_master.conf"),
+ }
+}
+
+class bind_slave inherits bind_base {
+ file { '/etc/named.conf':
+ content => template("bind/named_base.conf", "bind/named_slave.conf"),
+ }
+}
+
+