Dzahn has submitted this change and it was merged.

Change subject: redirect http->https on ishmael
......................................................................


redirect http->https on ishmael

enforce https on ishmael which is also behind
misc-web now

Change-Id: Id90f77b8c07e091d07ed2a6ccafec90e25d0ede3
---
M modules/ishmael/templates/apache/ishmael.wikimedia.org.erb
1 file changed, 5 insertions(+), 0 deletions(-)

Approvals:
  Chmarkine: Looks good to me, but someone else must approve
  jenkins-bot: Verified
  Dzahn: Looks good to me, approved



diff --git a/modules/ishmael/templates/apache/ishmael.wikimedia.org.erb 
b/modules/ishmael/templates/apache/ishmael.wikimedia.org.erb
index 6a2f7a9..60b5ed3 100644
--- a/modules/ishmael/templates/apache/ishmael.wikimedia.org.erb
+++ b/modules/ishmael/templates/apache/ishmael.wikimedia.org.erb
@@ -7,6 +7,11 @@
     ServerName <%= @site_name %>
     DocumentRoot <%= @docroot %>
 
+    RewriteEngine on
+    RewriteCond %{HTTP:X-Forwarded-Proto} !https
+    RewriteRule ^/(.*)$ https://%{HTTP_HOST}%{REQUEST_URI} 
[R=301,E=ProtoRedirect]
+    Header always merge Vary X-Forwarded-Proto env=ProtoRedirect
+
     <Directory "<%= @docroot %>">
         Options FollowSymLinks
         Options ExecCGI

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Id90f77b8c07e091d07ed2a6ccafec90e25d0ede3
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Dzahn <[email protected]>
Gerrit-Reviewer: Aklapper <[email protected]>
Gerrit-Reviewer: Alexandros Kosiaris <[email protected]>
Gerrit-Reviewer: Chmarkine <[email protected]>
Gerrit-Reviewer: Dzahn <[email protected]>
Gerrit-Reviewer: Matanya <[email protected]>
Gerrit-Reviewer: jenkins-bot <>

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

Reply via email to