Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

X-Forwarded-Proto is returning http,https instead of https since nginx version >= 1.23 #87

Open
elaman opened this issue Aug 2, 2023 · 1 comment

Comments

@elaman
Copy link
Contributor

elaman commented Aug 2, 2023

Motivation

We recently updated our Drupal website to use wodby/nginx:1.25-5.33.0 instead of wodby/nginx:1.19-5.25.6. Immediately we noticed that sitemap.xml was generated with links using http instead of https.

Investigation

The Simple Sitemap module is using $GLOBALS['base_url'] to generate links, which in turn relies on symfony/http-foundation method Request::isSecure. This method checks X-Forwarded-Proto header for http or https.

Proposed solution

Provide environmental variable to set the value for this header and override the default.

@csandanov
Copy link
Member

Sure, let's add it

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants