summaryrefslogtreecommitdiff
path: root/manifests/munin.pp
blob: 92a389f7e8acc8b67b517f9245220525f2423a75 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
class nagios::munin inherits munin::plugins::base {

    munin::plugin::deploy {
        nagios_hosts:
            source => 'nagios/munin/nagios_hosts',
            config => 'user root';
        nagios_svc:
            source => 'nagios/munin/nagios_svc',
            config => 'user root';
        nagios_perf_hosts:
            source => 'nagios/munin/nagios_perf',
            config => 'user root';
        nagios_perf_svc:
            source => 'nagios/munin/nagios_perf',
            config => 'user root';
    }

    exec { 'munin_nagios2stats_link':
        command => 'ln -s /usr/sbin/nagios2stats /usr/local/sbin/nagiostats',
        onlyif => ["test ! -e /usr/local/sbin/nagiostats", "test -e /usr/sbin/nagios2stats"],
    }

    exec { 'munin_nagios3stats_link':
        command => 'ln -s /usr/sbin/nagios3stats /usr/local/sbin/nagiostats',
        onlyif => ["test ! -e /usr/local/sbin/nagiostats", "test -e /usr/sbin/nagios3stats"],
    }

}