aboutsummaryrefslogtreecommitdiff
path: root/manifests/init.pp
diff options
context:
space:
mode:
Diffstat (limited to 'manifests/init.pp')
-rw-r--r--manifests/init.pp21
1 files changed, 13 insertions, 8 deletions
diff --git a/manifests/init.pp b/manifests/init.pp
index 34680fa..6e7b7fb 100644
--- a/manifests/init.pp
+++ b/manifests/init.pp
@@ -26,12 +26,6 @@ class nodo {
include utils
include cron
- # We include munin configuration if it's not defined by
- # and exported resource.
- if !defined(Munin_node[$hostname]) {
- include munin::client
- }
-
# Set timezone and ntp config
#
# We config those here but leave class inclusion elsewhere
@@ -167,6 +161,11 @@ class nodo::server inherits nodo {
mode => 0644,
ensure => present,
}
+
+ # Munin configuration
+ munin_node { "$hostname":
+ id => '00',
+ }
}
class nodo::vserver inherits nodo {
@@ -182,8 +181,14 @@ class nodo::vserver inherits nodo {
dohwinfo => false,
}
- # Apply munin configuration for this node
- Munin_node <<| tag == $hostname |>>
+ # We include munin configuration if it's not defined by
+ # and exported resource.
+ if !defined(Munin_node[$hostname]) {
+ include munin::client
+ } else {
+ # Apply munin configuration for this node
+ Munin_node <<| tag == $hostname |>>
+ }
# Define a vserver instance
define instance($context, $ensure = 'running', $proxy = false, $puppetmaster = false, $gitd = false,