Alexandros Kosiaris has uploaded a new change for review.
https://gerrit.wikimedia.org/r/279133
Change subject: Revert "ores: Hardcode Host in the HTTPS redirect"
......................................................................
Revert "ores: Hardcode Host in the HTTPS redirect"
Honor instead the Host header sent by the client in the HTTP request
This reverts commit 20bf8c3680f04aa05b2c03d0cf6941bdc39b6490.
Bug: T130618
Change-Id: Ia1634015928672bc4d2fc5d7cbcb88cc3fb0ee59
---
M modules/ores/manifests/web.pp
M modules/ores/templates/lb.nginx.erb
2 files changed, 2 insertions(+), 1 deletion(-)
git pull ssh://gerrit.wikimedia.org:29418/operations/puppet
refs/changes/33/279133/1
diff --git a/modules/ores/manifests/web.pp b/modules/ores/manifests/web.pp
index e21f188..4581bec 100644
--- a/modules/ores/manifests/web.pp
+++ b/modules/ores/manifests/web.pp
@@ -19,7 +19,7 @@
venv => $ores::base::venv_path,
processes => inline_template("<%= @processorcount.to_i *
${workers_per_core} %>"),
# lint:ignore:single_quote_string_with_variables
- route-if => 'equal:${HTTP_X_FORWARDED_PROTO};http
redirect-permanent:https://ores.wmflabs.org${REQUEST_URI}',
+ route-if => 'equal:${HTTP_X_FORWARDED_PROTO};http
redirect-permanent:https://${HTTP_HOST}${REQUEST_URI}',
# lint:endignore
}
}
diff --git a/modules/ores/templates/lb.nginx.erb
b/modules/ores/templates/lb.nginx.erb
index 36a713f..66552a6 100644
--- a/modules/ores/templates/lb.nginx.erb
+++ b/modules/ores/templates/lb.nginx.erb
@@ -18,6 +18,7 @@
location / {
<% if @cache %>proxy_cache ores;<% end %>
proxy_pass http://oresweb;
+ proxy_set_header Host $host;
add_header 'Access-Control-Allow-Origin' '*';
}
}
--
To view, visit https://gerrit.wikimedia.org/r/279133
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: Ia1634015928672bc4d2fc5d7cbcb88cc3fb0ee59
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Alexandros Kosiaris <[email protected]>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits