]> git.donarmstrong.com Git - dsa-puppet.git/blob - modules/roles/manifests/init.pp
try to rolify dns
[dsa-puppet.git] / modules / roles / manifests / init.pp
1 class roles {
2
3         $roles = hiera('roles')
4
5         if $::fqdn in $roles['puppetmaster'] {
6                 include puppetmaster
7         }
8
9         if getfromhash($site::nodeinfo, 'muninmaster') {
10                 include munin::master
11         }
12
13         if getfromhash($site::nodeinfo, 'nagiosmaster') {
14         #       include nagios::server
15                 ssl::service { 'nagios.debian.org':
16                         notify => Service['apache2'],
17                 }
18         }
19
20         if getfromhash($site::nodeinfo, 'buildd') {
21                 include buildd
22         }
23
24         if getfromhash($site::nodeinfo, 'porterbox') {
25                 include porterbox
26         }
27
28         if getfromhash($site::nodeinfo, 'bugs_mirror') {
29                 include roles::bugs_mirror
30         }
31
32         if getfromhash($site::nodeinfo, 'ftp_master') {
33                 include roles::ftp_master
34                 include roles::dakmaster
35         }
36
37         if getfromhash($site::nodeinfo, 'apache2_security_mirror') {
38                 include roles::security_mirror
39         }
40
41         if getfromhash($site::nodeinfo, 'apache2_www_mirror') {
42                 include roles::www_mirror
43         }
44
45         if getfromhash($site::nodeinfo, 'ftp.d.o') {
46                 include roles::ftp
47         }
48
49         if getfromhash($site::nodeinfo, 'ftp.upload.d.o') {
50                 include roles::ftp_upload
51         }
52
53         if getfromhash($site::nodeinfo, 'security_master') {
54                 include roles::security_master
55                 include roles::dakmaster
56         }
57
58         if getfromhash($site::nodeinfo, 'www_master') {
59                 include roles::www_master
60         }
61
62         if getfromhash($site::nodeinfo, 'keyring') {
63                 include roles::keyring
64         }
65
66         if getfromhash($site::nodeinfo, 'wiki') {
67                 include roles::wiki
68         }
69
70         if getfromhash($site::nodeinfo, 'syncproxy') {
71                 include roles::syncproxy
72         }
73
74         if getfromhash($site::nodeinfo, 'static_master') {
75                 include roles::static_master
76         }
77
78         if getfromhash($site::nodeinfo, 'static_mirror') {
79                 include roles::static_mirror
80         } elsif getfromhash($site::nodeinfo, 'static_source') {
81                 include roles::static_source
82         }
83
84         if getfromhash($site::nodeinfo, 'weblog_provider') {
85                 include roles::weblog_provider
86         }
87
88         if getfromhash($site::nodeinfo, 'mailrelay') {
89                 include roles::mailrelay
90         }
91
92         if getfromhash($site::nodeinfo, 'pubsub') {
93                 include roles::pubsub
94         }
95
96         if getfromhash($site::nodeinfo, 'dbmaster') {
97                 ssl::service { 'db.debian.org':
98                         notify => Service['apache2'],
99                 }
100         }
101
102         if getfromhash($site::nodeinfo, 'dns_primary') {
103                 include named::primary
104         }
105         if getfromhash($site::nodeinfo, 'dns_secondary') {
106                 include named::authoritative
107         }
108
109         if $::hostname in [ravel] {
110                 include roles::weblog_destination
111         }
112
113         if $::hostname in [vento] {
114                 ssl::service { 'vote.debian.org':
115                         notify => Service['apache2'],
116                 }
117         }
118
119         if $::hostname in [soler] {
120                 ssl::service { 'security-tracker.debian.org':
121                         notify => Service['apache2'],
122                 }
123         }
124
125         if $::hostname in [bendel] {
126                 ssl::service { 'lists.debian.org':
127                         notify => Service['apache2'],
128                 }
129         }
130
131         if $::hostname in [reger] {
132                 ssl::service { 'rt.debian.org':
133                         notify => Service['apache2'],
134                 }
135         }
136
137         if $::hostname in [diabelli] {
138                 ssl::service { 'sso.debian.org':
139                         notify => Service['apache2'],
140                 }
141         }
142
143         if $::hostname in [ullmann] {
144                 ssl::service { 'udd.debian.org':
145                         notify => Service['apache2'],
146                 }
147         }
148         
149         if $::hostname in [wuiet] {
150                 ssl::service { 'buildd.debian.org':
151                         notify => Service['apache2'],
152                 }
153         }
154
155         if $::hostname in [pejacevic] {
156                 ssl::service { 'piuparts.debian.org':
157                         notify => Service['apache2'],
158                 }
159         }
160
161         if $::hostname in [nono] {
162                 ssl::service { 'nm.debian.org':
163                         notify => Service['apache2'],
164                 }
165                 ssl::service { 'contributors.debian.org':
166                         notify => Service['apache2'],
167                 }
168         }
169
170         if $::hostname in [franck] {
171                 ssl::service { 'release.debian.org':
172                         notify => Service['apache2'],
173                 }
174         }
175 }