AndyRussG has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/182141

Change subject: Add comment about not redirecting ugly URLs
......................................................................

Add comment about not redirecting ugly URLs

Change-Id: I71deb45d610b5dd883fd2fb61a2b6abd0db221d4
---
M templates/varnish/text-frontend.inc.vcl.erb
1 file changed, 3 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/puppet 
refs/changes/41/182141/1

diff --git a/templates/varnish/text-frontend.inc.vcl.erb 
b/templates/varnish/text-frontend.inc.vcl.erb
index b63d51c..a29a5e3 100644
--- a/templates/varnish/text-frontend.inc.vcl.erb
+++ b/templates/varnish/text-frontend.inc.vcl.erb
@@ -41,6 +41,9 @@
 }
 
 sub mobile_redirect {
+
+       # Don't redirect long URLs ('/w/index.php?title=...'). This feature is
+       # important for CentralNotice calls to meta for displaying banners.
        if ( (req.request == "GET" || req.request == "HEAD")
                && (req.http.User-Agent ~ 
"(?i)(mobi|240x240|240x320|320x320|alcatel|android|audiovox|bada|benq|blackberry|cdm-|compal-|docomo|ericsson|hiptop|htc[-_]|huawei|ipod|kddi-|kindle|meego|midp|mitsu|mmp\/|mot-|motor|ngm_|nintendo|opera.m|palm|panasonic|philips|phone|playstation|portalmmm|sagem-|samsung|sanyo|sec-|semc-browser|sendo|sharp|silk|softbank|symbian|teleca|up.browser|vodafone|webos)"
                        || req.http.User-Agent ~ "^(?i)(lge?|sie|nec|sgh|pg)-" 
|| req.http.Accept ~ "vnd.wap.wml")

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I71deb45d610b5dd883fd2fb61a2b6abd0db221d4
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: AndyRussG <[email protected]>

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

Reply via email to