Giuseppe Lavagetto has submitted this change and it was merged.
Change subject: Send wikipedia.org/apple-app-site-association to the right file
without an external redirect
......................................................................
Send wikipedia.org/apple-app-site-association to the right file without an
external redirect
And on www.
Bug: T131250
Change-Id: Ib09c5cd9671636c62749de7b9abe6e374136937c
---
M modules/mediawiki/templates/apache/sites/wwwportals.conf.erb
1 file changed, 9 insertions(+), 0 deletions(-)
Approvals:
Fjalapeno: Looks good to me, but someone else must approve
Brion VIBBER: Looks good to me, but someone else must approve
Giuseppe Lavagetto: Verified; Looks good to me, approved
diff --git a/modules/mediawiki/templates/apache/sites/wwwportals.conf.erb
b/modules/mediawiki/templates/apache/sites/wwwportals.conf.erb
index 394829b..747dfbc 100644
--- a/modules/mediawiki/templates/apache/sites/wwwportals.conf.erb
+++ b/modules/mediawiki/templates/apache/sites/wwwportals.conf.erb
@@ -8,6 +8,11 @@
RewriteRule . - [E=RW_PROTO:http]
RewriteRule ^/([a-z]{2}|meta)/(.*)$ %{ENV:RW_PROTO}://$1.wikipedia.<%=
@domain_suffix %>/wiki/$2 [R=301,L,NE]
+
+ # Prevent the catch-all redirect below from breaking the
apple-app-site-association alias
+ RewriteRule /apple-app-site-association - [L]
+ Alias /apple-app-site-association
/srv/mediawiki/docroot/wikipedia.org/apple-app-site-association
+
RewriteRule ^(.*)$ %{ENV:RW_PROTO}://www.wikipedia.<%= @domain_suffix %>$1
[R=301,L]
</VirtualHost>
@@ -55,6 +60,10 @@
RewriteRule ^/wiki\.cgi$ %{ENV:RW_PROTO}://en.wikipedia.<%= @domain_suffix
%>/wiki/%1 [R=302,L]
RewriteRule ^/wiki\.cgi$ %{ENV:RW_PROTO}://en.wikipedia.<%= @domain_suffix
%>/ [R=302,L]
+ # Prevent the catch-all redirect below from breaking the
apple-app-site-association alias
+ RewriteRule /apple-app-site-association - [L]
+ Alias /apple-app-site-association
/srv/mediawiki/docroot/wikipedia.org/apple-app-site-association
+
# Everything else
RewriteRule ^(.*)$ %{ENV:RW_PROTO}://en.wikipedia.<%= @domain_suffix %>$1
[R=301,L]
--
To view, visit https://gerrit.wikimedia.org/r/281900
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: merged
Gerrit-Change-Id: Ib09c5cd9671636c62749de7b9abe6e374136937c
Gerrit-PatchSet: 5
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Alex Monk <[email protected]>
Gerrit-Reviewer: Alex Monk <[email protected]>
Gerrit-Reviewer: Brion VIBBER <[email protected]>
Gerrit-Reviewer: Fjalapeno <[email protected]>
Gerrit-Reviewer: Giuseppe Lavagetto <[email protected]>
Gerrit-Reviewer: jenkins-bot <>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits