]> git.donarmstrong.com Git - dsa-puppet.git/blob - modules/geodns/manifests/init.pp
gluck to default-apache
[dsa-puppet.git] / modules / geodns / manifests / init.pp
1 class geodns {
2
3         package {
4                 bind9: ensure => installed;
5         }
6
7         file {
8                 "/etc/apt/sources.list.d/geoip.list":
9                         source => "puppet:///files/etc/apt/sources.list.d/geoip.list",
10                         notify  => Exec["apt-get update"],
11                         ;
12                 "/etc/bind/named.conf.local":
13                         source  => [ "puppet:///geodns/per-host/$fqdn/named.conf.local",
14                                      "puppet:///geodns/common/named.conf.local" ],
15                         require => Package["bind9"],
16                         notify  => Exec["bind9 restart"],
17                         owner   => root,
18                         group   => root,
19                         ;
20                 "/etc/bind/named.conf.acl":
21                         source  => [ "puppet:///geodns/per-host/$fqdn/named.conf.acl",
22                                      "puppet:///geodns/common/named.conf.acl" ],
23                         require => Package["bind9"],
24                         notify  => Exec["bind9 restart"],
25                         owner   => root,
26                         group   => root,
27                         ;
28                 "/etc/bind/named.conf.options":
29                         source  => [ "puppet:///geodns/per-host/$fqdn/named.conf.options",
30                                      "puppet:///geodns/common/named.conf.options" ],
31                         require => Package["bind9"],
32                         notify  => Exec["bind9 restart"],
33                         owner   => root,
34                         group   => root,
35                         ;
36
37                 "/etc/bind/geodns":
38                         ensure  => directory,
39                         owner   => root,
40                         group   => geodnssync,
41                         mode    => 775,
42                         ;
43                 "/etc/bind/geodns/recvconf":
44                         source  => [ "puppet:///geodns/per-host/$fqdn/recvconf",
45                                      "puppet:///geodns/common/recvconf" ],
46                         owner   => root,
47                         group   => root,
48                         mode    => 555,
49                         ;
50                 "/etc/bind/geodns/recvconf.files":
51                         source  => [ "puppet:///geodns/per-host/$fqdn/recvconf.files",
52                                      "puppet:///geodns/common/recvconf.files" ],
53                         owner   => root,
54                         group   => root,
55                         mode    => 444,
56                         ;
57
58                 "/etc/ssh/userkeys/geodnssync":
59                         source  => [ "puppet:///geodns/per-host/$fqdn/authorized_keys",
60                                      "puppet:///geodns/common/authorized_keys" ],
61                         owner   => root,
62                         group   => geodnssync,
63                         mode    => 440,
64                         ;
65         }
66
67         exec {
68                 "bind9 restart":
69                         path        => "/etc/init.d:/usr/bin:/usr/sbin:/bin:/sbin",
70                         refreshonly => true,
71                         ;
72         }
73 }
74
75 # vim: set fdm=marker ts=8 sw=8 et: