Mark Bergsma has submitted this change and it was merged.

Change subject: Add a custom error page to the upload cache cluster
......................................................................


Add a custom error page to the upload cache cluster

Change-Id: Ibce78bb02ecb79c8f8bd96e8cfcbe0aa6af9b53b
---
M templates/varnish/upload-backend.inc.vcl.erb
M templates/varnish/upload-frontend.inc.vcl.erb
2 files changed, 14 insertions(+), 0 deletions(-)

Approvals:
  Mark Bergsma: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/templates/varnish/upload-backend.inc.vcl.erb 
b/templates/varnish/upload-backend.inc.vcl.erb
index 31d8722..bfca3b6 100644
--- a/templates/varnish/upload-backend.inc.vcl.erb
+++ b/templates/varnish/upload-backend.inc.vcl.erb
@@ -1,5 +1,7 @@
 # Varnish VCL include file for upload backends
 
+include "errorpage.inc.vcl";
+
 sub pick_main_stevedore {
        if (std.random(0, 2) < 1) {
                set beresp.storage = "main1";
@@ -146,6 +148,11 @@
        }
 }
 
+sub vcl_error {
+       call errorpage;
+       return(deliver);
+}
+
 sub vcl_deliver {
        if (resp.http.X-Content-Range) {
                set resp.http.Content-Range = resp.http.X-Content-Range;
diff --git a/templates/varnish/upload-frontend.inc.vcl.erb 
b/templates/varnish/upload-frontend.inc.vcl.erb
index 8bc6d24..66e14a9 100644
--- a/templates/varnish/upload-frontend.inc.vcl.erb
+++ b/templates/varnish/upload-frontend.inc.vcl.erb
@@ -1,5 +1,7 @@
 # Varnish VCL include file for upload frontends
 
+include "errorpage.inc.vcl";
+
 sub vcl_recv {
        call vcl_recv_purge;
 
@@ -64,6 +66,11 @@
        }
 }
 
+sub vcl_error {
+       call errorpage;
+       return(deliver);
+}
+
 sub vcl_deliver {
        if (resp.http.X-Content-Range) {
                set resp.http.Content-Range = resp.http.X-Content-Range;

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Ibce78bb02ecb79c8f8bd96e8cfcbe0aa6af9b53b
Gerrit-PatchSet: 2
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Mark Bergsma <[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