Andrew Bogott has uploaded a new change for review.
https://gerrit.wikimedia.org/r/194959
Change subject: Force https for horizon, take two
......................................................................
Force https for horizon, take two
Change-Id: If81d54aee5c9bd97a552b8263b7116030458cac1
---
M modules/openstack/manifests/horizon/service.pp
M modules/openstack/templates/icehouse/horizon/openstack-dashboard.conf.erb
2 files changed, 6 insertions(+), 3 deletions(-)
git pull ssh://gerrit.wikimedia.org:29418/operations/puppet
refs/changes/59/194959/1
diff --git a/modules/openstack/manifests/horizon/service.pp
b/modules/openstack/manifests/horizon/service.pp
index 49044b6..c1b50fa 100644
--- a/modules/openstack/manifests/horizon/service.pp
+++ b/modules/openstack/manifests/horizon/service.pp
@@ -17,6 +17,7 @@
include apache::mod::wsgi
include ::apache::mod::rewrite
+ include ::apache::mod::headers
if !defined(Class['memcached']) {
class { 'memcached':
diff --git
a/modules/openstack/templates/icehouse/horizon/openstack-dashboard.conf.erb
b/modules/openstack/templates/icehouse/horizon/openstack-dashboard.conf.erb
index 3e5196d..e21561d 100755
--- a/modules/openstack/templates/icehouse/horizon/openstack-dashboard.conf.erb
+++ b/modules/openstack/templates/icehouse/horizon/openstack-dashboard.conf.erb
@@ -1,6 +1,8 @@
-RewriteEngine On
-RewriteCond %{HTTPS} !=on
-RewriteRule ^/?(.*) https://%{SERVER_NAME}/$1 [R,L]
+RewriteEngine on
+RewriteCond %{HTTP:X-Forwarded-Proto} !https
+RewriteCond %{REQUEST_URI} !^/status$
+RewriteRule ^/(.*)$ https://%{HTTP_HOST}%{REQUEST_URI} [R=301,E=ProtoRedirect]
+Header always merge Vary X-Forwarded-Proto env=ProtoRedirect
WSGIScriptAlias /
/usr/share/openstack-dashboard/openstack_dashboard/wsgi/django.wsgi
WSGIDaemonProcess horizon user=horizon group=horizon processes=3 threads=10
--
To view, visit https://gerrit.wikimedia.org/r/194959
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: If81d54aee5c9bd97a552b8263b7116030458cac1
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Andrew Bogott <[email protected]>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits