Left: | ||
Right: |
OLD | NEW |
---|---|
1 class nagios::server( | 1 class nagios::server( |
2 $domain, | 2 $domain, |
3 $certificate, | 3 $certificate, |
4 $private_key, | 4 $private_key, |
5 $is_default=false, | 5 $is_default=false, |
6 $htpasswd_source, | 6 $htpasswd_source, |
7 $admins | 7 $admins |
8 ) { | 8 ) { |
9 | 9 |
10 File { | 10 File { |
(...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
75 require => Package['nagios3'], | 75 require => Package['nagios3'], |
76 notify => Service['nagios3'] | 76 notify => Service['nagios3'] |
77 } | 77 } |
78 | 78 |
79 file {'/etc/nagios3/conf.d/generic-service.cfg': | 79 file {'/etc/nagios3/conf.d/generic-service.cfg': |
80 source => 'puppet:///modules/nagios/generic-service.cfg', | 80 source => 'puppet:///modules/nagios/generic-service.cfg', |
81 require => Package['nagios3'], | 81 require => Package['nagios3'], |
82 notify => Service['nagios3'] | 82 notify => Service['nagios3'] |
83 } | 83 } |
84 | 84 |
85 file {['/etc/nagios3/conf.d/contacts_nagios2.cfg', | 85 file {['/etc/nagios3/conf.d/contacts_nagios2.cfg', |
mathias
2014/07/10 10:22:17
Another possible optimization here: We could proba
Wladimir Palant
2014/07/10 10:38:20
I don't think Puppet allows pattern matches for fi
| |
86 '/etc/nagios3/conf.d/extinfo_nagios2.cfg', | 86 '/etc/nagios3/conf.d/extinfo_nagios2.cfg', |
87 '/etc/nagios3/conf.d/generic-host_nagios2.cfg', | 87 '/etc/nagios3/conf.d/generic-host_nagios2.cfg', |
88 '/etc/nagios3/conf.d/generic-service_nagios2.cfg', | 88 '/etc/nagios3/conf.d/generic-service_nagios2.cfg', |
89 '/etc/nagios3/conf.d/hosts_nagios2.cfg', | 89 '/etc/nagios3/conf.d/hosts_nagios2.cfg', |
90 '/etc/nagios3/conf.d/hostgroups_nagios2.cfg', | 90 '/etc/nagios3/conf.d/hostgroups_nagios2.cfg', |
91 '/etc/nagios3/conf.d/localhost_nagios2.cfg', | 91 '/etc/nagios3/conf.d/localhost_nagios2.cfg', |
92 '/etc/nagios3/conf.d/services_nagios2.cfg']: | 92 '/etc/nagios3/conf.d/services_nagios2.cfg']: |
93 ensure => absent | 93 ensure => absent, |
94 require => Package['nagios3'], | |
95 before => Service['nagios3'] | |
mathias
2014/07/10 10:22:17
Almost sure.
As far as I can see these files are
| |
94 } | 96 } |
95 | 97 |
96 resources {['nagios_contact', 'nagios_contactgroup', 'nagios_host', | 98 resources {['nagios_contact', 'nagios_contactgroup', 'nagios_host', |
97 'nagios_hostgroup', 'nagios_service']: | 99 'nagios_hostgroup', 'nagios_service']: |
98 purge => true | 100 purge => true |
99 } | 101 } |
100 | 102 |
101 Nagios_contact <| |> { | 103 Nagios_contact <| |> { |
102 target => '/etc/nagios3/conf.d/contacts.cfg', | 104 target => '/etc/nagios3/conf.d/contacts.cfg', |
103 require => Package['nagios3'], | 105 require => Package['nagios3'], |
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
137 file {['/etc/nagios3/conf.d/contacts.cfg', | 139 file {['/etc/nagios3/conf.d/contacts.cfg', |
138 '/etc/nagios3/conf.d/contactgroups.cfg', | 140 '/etc/nagios3/conf.d/contactgroups.cfg', |
139 '/etc/nagios3/conf.d/commands.cfg', | 141 '/etc/nagios3/conf.d/commands.cfg', |
140 '/etc/nagios3/conf.d/hosts.cfg', | 142 '/etc/nagios3/conf.d/hosts.cfg', |
141 '/etc/nagios3/conf.d/hostgroups.cfg', | 143 '/etc/nagios3/conf.d/hostgroups.cfg', |
142 '/etc/nagios3/conf.d/services.cfg']: | 144 '/etc/nagios3/conf.d/services.cfg']: |
143 require => Package['nagios3'], | 145 require => Package['nagios3'], |
144 notify => Service['nagios3'] | 146 notify => Service['nagios3'] |
145 } | 147 } |
146 } | 148 } |
OLD | NEW |