From: Silvio Rhatto Date: Fri, 7 Jun 2013 18:59:08 +0000 (-0300) Subject: Setting mysql_ munin plugins on nodo::role::mail X-Git-Url: https://gitweb.fluxo.info/?a=commitdiff_plain;h=8bd2bc0082954b059866f697d2b211f85c5adb7c;p=puppet-nodo.git Setting mysql_ munin plugins on nodo::role::mail --- diff --git a/manifests/role/mail.pp b/manifests/role/mail.pp index 717d57f..f486313 100644 --- a/manifests/role/mail.pp +++ b/manifests/role/mail.pp @@ -1,8 +1,24 @@ class nodo::role::mail { class { [ 'nodo::role::vserver', 'mail::system' ]: } + # Config parameters + $delivery = hiera('nodo::subsystem::mail::delivery', 'exim') + $virtual = hiera('mail::virtual', false) + # Graph postfix munin::plugin { [ 'postfix_mailqueue', 'postfix_mailstats' ]: - ensure => present, + ensure => $delivery ? { + 'postfix' => present, + default => absent, + }, + } + + # Graph mysql + munin::plugin { [ 'mysql_queries', 'mysql_slowqueries', 'mysql_bytes', 'mysql_threads' ]: + config => "user root", + ensure => $virtual ? { + true => present, + default => absent, + }, } }