Giuseppe Lavagetto has submitted this change and it was merged.

Change subject: role::cache: make ganglia inclusion optional
......................................................................


role::cache: make ganglia inclusion optional

Change-Id: If984cc6bf71723e4730982825978477d2ae86d6d
Signed-off-by: Giuseppe Lavagetto <[email protected]>
---
M manifests/role/cache.pp
1 file changed, 18 insertions(+), 7 deletions(-)

Approvals:
  Giuseppe Lavagetto: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/manifests/role/cache.pp b/manifests/role/cache.pp
index d2c4a9b..9b8ba2a 100644
--- a/manifests/role/cache.pp
+++ b/manifests/role/cache.pp
@@ -54,6 +54,8 @@
     class configuration {
         include lvs::configuration
 
+        $has_ganglia = hiera('has_ganglia', true)
+
         $active_nodes = {
             'production' => {
                 'text' => {
@@ -761,8 +763,9 @@
         # unless they're overridden!
         $backend_weight = 10
 
-        # Ganglia monitoring
-        class { 'varnish::monitoring::ganglia': }
+        if $::role::cache::configuration::has_ganglia {
+            include varnish::monitoring::ganglia
+        }
     }
 
     # Ancestor class for common resources of 2-layer clusters
@@ -781,8 +784,10 @@
         }
 
         # Ganglia monitoring
-        class { 'varnish::monitoring::ganglia':
-            varnish_instances => [ '', 'frontend' ],
+        if $::role::cache::configuration::has_ganglia{
+            class { 'varnish::monitoring::ganglia':
+                varnish_instances => [ '', 'frontend' ],
+            }
         }
     }
 
@@ -829,7 +834,9 @@
             varnish_instances => [ '127.0.0.1:80', '127.0.0.1:3128' ],
         }
 
-        include varnish::monitoring::ganglia::vhtcpd
+        if $::role::cache::configuration::has_ganglia {
+            include varnish::monitoring::ganglia::vhtcpd
+        }
 
         $runtime_params = $::site ? {
             #'esams' => ['prefer_ipv6=on','default_ttl=2592000'],
@@ -998,7 +1005,9 @@
             varnish_instances => [ '127.0.0.1:80', '127.0.0.1:3128' ],
         }
 
-        include varnish::monitoring::ganglia::vhtcpd
+        if $::role::cache::configuration::has_ganglia {
+            include varnish::monitoring::ganglia::vhtcpd
+        }
 
         case $::realm {
             'production': {
@@ -1257,7 +1266,9 @@
             varnish_instances => [ '127.0.0.1:80', '127.0.0.1:3128' ],
         }
 
-        include varnish::monitoring::ganglia::vhtcpd
+        if $::role::cache::configuration::has_ganglia {
+            include varnish::monitoring::ganglia::vhtcpd
+        }
 
         case $::realm {
             'production': {

-- 
To view, visit https://gerrit.wikimedia.org/r/172974
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: If984cc6bf71723e4730982825978477d2ae86d6d
Gerrit-PatchSet: 4
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Giuseppe Lavagetto <[email protected]>
Gerrit-Reviewer: Giuseppe Lavagetto <[email protected]>
Gerrit-Reviewer: Mark Bergsma <[email protected]>
Gerrit-Reviewer: jenkins-bot <>

_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to