aboutsummaryrefslogtreecommitdiff
path: root/manifests/subsystem/monitor
diff options
context:
space:
mode:
authorSilvio Rhatto <rhatto@riseup.net>2015-09-11 21:16:42 -0300
committerSilvio Rhatto <rhatto@riseup.net>2015-09-11 21:16:42 -0300
commit76ec4642be1a8bc64380c077a5890c4d0f4243e0 (patch)
treee31930271b7eefb3c3d693264e012e8ff45832ae /manifests/subsystem/monitor
parent6509060a791daeeee13c40f9367489ac5e00880e (diff)
downloadpuppet-nodo-76ec4642be1a8bc64380c077a5890c4d0f4243e0.tar.gz
puppet-nodo-76ec4642be1a8bc64380c077a5890c4d0f4243e0.tar.bz2
Autoload definitions
Diffstat (limited to 'manifests/subsystem/monitor')
-rw-r--r--manifests/subsystem/monitor/munin.pp27
1 files changed, 27 insertions, 0 deletions
diff --git a/manifests/subsystem/monitor/munin.pp b/manifests/subsystem/monitor/munin.pp
new file mode 100644
index 0000000..aa70c2f
--- /dev/null
+++ b/manifests/subsystem/monitor/munin.pp
@@ -0,0 +1,27 @@
+# Define a munin node
+define nodo::sybsystem::monitor::munin(
+ $port = hiera('nodo::munin_node::port', '4949'),
+ $allow = hiera('nodo::munin_node::allow', ''),
+ $host = hiera('nodo::munin_node::host', $::fqdn),
+ $listen = hiera('nodo::munin_node::listen', '*'),
+ $config = hiera('nodo::munin_node::config', [ 'use_node_name yes', 'load.load.warning 5', 'load.load.critical 10' ])
+) {
+
+ case $allow {
+ '': { fail("Please set nodo::munin_node::allow in your config") }
+ }
+
+ package { "munin-plugins-extra":
+ ensure => "present",
+ }
+
+ class { 'munin::client':
+ port => $port,
+ allow => $allow,
+ host => $host,
+ listen => $listen,
+ config => $config,
+ }
+
+ munin::plugin { apt_all: ensure => present; }
+}