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

Fix 502 errors due to IPv6 #1175

Merged
merged 1 commit into from Jan 4, 2024
Merged

Conversation

Wielewout
Copy link
Contributor

Description

This does the same as #1149, there were only some merge conflicts in that PR preventing it to be merged.
So taking over that description:

This changes how the NGINX proxy server resolves to the underlying sharelatex service. The change is to use "localhost" instead of the IPv4 address 127.0.0.1. There is an inconsistency in the current configuration as the App.js for sharelatex binds to "localhost" not 127.0.0.1, so if localhost resolves to the IPv6 address ::1, then there's a misconfiguration between nginx and the node.js server.

To fix this, either we make a change in the app.js for sharelatex to always force IPv4 by providing a 127.0.0.1 , or we just use whatever localhost binds to in both. For me, I think it is more logical to bind to localhost consistently, allowing the use of IPv6 or IPv4, whatever is preferred by the underlying system for "localhost".

Related issues / Pull Requests

Fixes #1146
Related to #1149

Contributor Agreement

@Doomsdayrs
Copy link

@aeaton-overleaf Can this be reviewed?

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.

502 Bad Gateway when ipv6 is available
3 participants