Skip to content

Proxito: fix https and canonical redirects #8193

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

Merged
merged 4 commits into from
May 19, 2021
Merged

Conversation

stsewd
Copy link
Member

@stsewd stsewd commented May 19, 2021

When doing a https redirect we were adding the default language and
version (/en/latest/) if the current url didn't have those components.
And similar when doing a redirect to a canonical domain.

Fix #8183

This is based on #8187 since we need to distinguish between redirects to subprojects and canonical redirects.

Closes #7881
We can revert #7880
after releasing this.
@stsewd stsewd requested review from ericholscher and a team May 19, 2021 00:35
When doing a https redirect we were adding the default language and
version (/en/latest/) if the current url didn't have those components.
And similar when doing a redirect to a canonical domain.

Fix #8183
@stsewd stsewd force-pushed the fix-proxito-redirects branch from 0b5deb2 to 810abd3 Compare May 19, 2021 00:36
Copy link
Member

@ericholscher ericholscher left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't quite understand the issue. What's wrong with adding the full URL when redirecting users?

Edit: Oh, I looked at the linked issue more closely. Makes sense.

Copy link
Member

@ericholscher ericholscher left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This makes sense, though adds another redirect for a lot of URL's :/

@@ -0,0 +1,3 @@
REDIRECT_HTTPS = 'https'
REDIRECT_CANONICAL_CNAME = 'canonical-cname'
REDIRECT_SUBPROJECT_MAIN_DOMAIN = 'subproject-main-domain'
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💯

@stsewd
Copy link
Member Author

stsewd commented May 19, 2021

This is based on #8187, so I need a review on that one first.

Base automatically changed from redirect-main-domain to master May 19, 2021 22:46
@stsewd stsewd merged commit 1ace680 into master May 19, 2021
@stsewd stsewd deleted the fix-proxito-redirects branch May 19, 2021 23:00
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

Successfully merging this pull request may close these issues.

Redirect only works with URL prefixed with HTTPS not HTTP
2 participants