-
Notifications
You must be signed in to change notification settings - Fork 1.5k
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
Redirect 80 to 443 in case for dynamic IP #3278
Comments
I am not sure what you are asking, from what you have written. |
Trying to rephrase my question, want to redirect any incoming http request to https. Server IP might not be the same always. As of now I was using static IP to test the redirection. Not Using the domain name in info.vhost_name. In the case where IP might vary based on the network configuration, what will be the best way to handle the http->https redirection. Thanks ! |
Isn't the problem that in your case, you are not sure in the code where to redirect to, in terms of You can try fish the information that got it to port 80 on the right box, out of another header that was sent by the browser as part of the :80 request, eg, HOST or AUTHORITY. You can serve on port 80 the redirect using eg 302 and Location: Another alternative is just serve a JS redirect which uses the original |
Hi Andy ,
I wanted to have a redirect from port 80 to 443 implemented for dynamic IPs of the server.
Initially tried with minimal example with two separate mounts for port 80 and port 443, with .origin as the redirect location.
But this happens while we set the context. Is there any better way to address this scenario.
I have upgraded to latest stable version on Livwebsocketv3.4stable as per your suggestion. We are using it on FreeRTOS.
Attaching the image of the current configuration.
THanks,
Som
The text was updated successfully, but these errors were encountered: