Ori.livneh has submitted this change and it was merged.

Change subject: ganglia-web: don't send Content-Disposition header with JSON / 
CSV data
......................................................................


ganglia-web: don't send Content-Disposition header with JSON / CSV data

Make Ganglia not send a "Content-Disposition: inline; filename=..." header when
responding to requests for CSV or JSON data, so that such data could be more
easily viewed in the browser.

Change-Id: I626eb3020f1e4eb5d4d648cc563c9e391227558d
---
M modules/ganglia/manifests/web.pp
1 file changed, 10 insertions(+), 0 deletions(-)

Approvals:
  Ori.livneh: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/modules/ganglia/manifests/web.pp b/modules/ganglia/manifests/web.pp
index 1d46619..4b25cd9 100644
--- a/modules/ganglia/manifests/web.pp
+++ b/modules/ganglia/manifests/web.pp
@@ -50,6 +50,16 @@
         require => Package['ganglia-webfrontend'],
     }
 
+    # Comment out the lines that add the 'Content-Disposition: inline; 
filename=...'
+    # header to responses to requests for CSV or JSON data. This should be a 
patch
+    # in the ganglia-webfrontend package, probably. -- Ori 18-Apr-2016
+    exec { 'comment_out_content_disposition_headers':
+        command => '/bin/sed -i "/header(\"Content-Disposition/s/^/#/" 
graph.php',
+        onlyif  => '/bin/grep -q "^    header(\"Content-Disposition" 
graph.php',
+        cwd     => '/usr/share/ganglia-webfrontend',
+        require => Package['ganglia-webfrontend'],
+    }
+
     # Increase the default memory limit
     file_line { 'php.ini-memory':
         line   => 'memory_limit = 768M',

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I626eb3020f1e4eb5d4d648cc563c9e391227558d
Gerrit-PatchSet: 3
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Ori.livneh <o...@wikimedia.org>
Gerrit-Reviewer: Ori.livneh <o...@wikimedia.org>
Gerrit-Reviewer: jenkins-bot <>

_______________________________________________
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to