]> gitweb.fluxo.info Git - puppet-nodo.git/commitdiff
Defining monitor class at nodo::host only if not previously declared
authorSilvio Rhatto <rhatto@riseup.net>
Sun, 20 Jan 2013 20:05:08 +0000 (18:05 -0200)
committerSilvio Rhatto <rhatto@riseup.net>
Sun, 20 Jan 2013 20:05:08 +0000 (18:05 -0200)
manifests/host.pp

index cae28ce5e60f41ddfb193f74237b7e4b212d3c18..b9c2a6b08dec004fcca1f8f5b8d853fec31225af 100644 (file)
@@ -18,9 +18,11 @@ class nodo::host inherits nodo {
   include vserver::host
 
   # Monitoring
-  class { 'monitor':
-    type       => 'host',
-    use_nagios => extlookup('host_use_nagios', 'true'),
+  if !defined('monitor') {
+    class { 'monitor':
+      type       => 'host',
+      use_nagios => extlookup('host_use_nagios', 'true'),
+    }
   }
 
   # Time configuration