]> git.donarmstrong.com Git - dsa-puppet.git/blob - modules/named/manifests/geodns.pp
e9ef8efd7f352c8ff285ebe87c0b059559759b77
[dsa-puppet.git] / modules / named / manifests / geodns.pp
1 class named::geodns inherits named {
2         file {
3                 "/etc/apt/sources.list.d/geoip.list":
4                         content => template("debian-org/etc/apt/sources.list.d/geoip.list.erb"),
5                         notify  => Exec["apt-get update"],
6                         ;
7                 "/etc/bind/named.conf.local":
8                         source  => [ "puppet:///geodns/per-host/$fqdn/named.conf.local",
9                                      "puppet:///geodns/common/named.conf.local" ],
10                         require => Package["bind9"],
11                         notify  => Exec["bind9 restart"],
12                         owner   => root,
13                         group   => root,
14                         ;
15                 "/etc/bind/named.conf.acl":
16                         source  => [ "puppet:///geodns/per-host/$fqdn/named.conf.acl",
17                                      "puppet:///geodns/common/named.conf.acl" ],
18                         require => Package["bind9"],
19                         notify  => Exec["bind9 restart"],
20                         owner   => root,
21                         group   => root,
22                         ;
23                 "/etc/bind/named.conf.options":
24                         source  => [ "puppet:///geodns/per-host/$fqdn/named.conf.options",
25                                      "puppet:///geodns/common/named.conf.options" ],
26                         require => Package["bind9"],
27                         notify  => Exec["bind9 restart"],
28                         owner   => root,
29                         group   => root,
30                         ;
31
32                 "/etc/bind/geodns":
33                         ensure  => directory,
34                         owner   => root,
35                         group   => geodnssync,
36                         mode    => 775,
37                         ;
38                 "/etc/bind/geodns/named.conf.geo":
39                         source  => [ "puppet:///geodns/per-host/$fqdn/named.conf.geo",
40                                      "puppet:///geodns/common/named.conf.geo" ],
41                         require => Package["bind9"],
42                         notify  => Exec["bind9 restart"],
43                         owner   => root,
44                         group   => root,
45                         ;
46                 "/etc/bind/geodns/recvconf":
47                         source  => [ "puppet:///geodns/per-host/$fqdn/recvconf",
48                                      "puppet:///geodns/common/recvconf" ],
49                         owner   => root,
50                         group   => root,
51                         mode    => 555,
52                         ;
53                 "/etc/bind/geodns/recvconf.files":
54                         source  => [ "puppet:///geodns/per-host/$fqdn/recvconf.files",
55                                      "puppet:///geodns/common/recvconf.files" ],
56                         owner   => root,
57                         group   => root,
58                         mode    => 444,
59                         ;
60
61                 "/usr/share/GeoIP/GeoIPv6.dat":
62                         source  => [ "puppet:///geodns/per-host/$fqdn/GeoIPv6.dat",
63                                      "puppet:///geodns/common/GeoIPv6.dat" ],
64                         owner   => root,
65                         group   => root,
66                         mode    => 444,
67                         ;
68
69                 "/etc/ssh/userkeys/geodnssync":
70                         source  => [ "puppet:///geodns/per-host/$fqdn/authorized_keys",
71                                      "puppet:///geodns/common/authorized_keys" ],
72                         owner   => root,
73                         group   => geodnssync,
74                         mode    => 440,
75                         ;
76                 "/var/log/bind9":
77                         ensure  => directory,
78                         owner   => bind,
79                         group   => bind,
80                         mode    => 775,
81                         ;
82         }
83 }
84
85 # vim: set fdm=marker ts=8 sw=8 et: