Task #5408
openUpate nginx documentation for non standard SSL port
0%
Description
I'm currently in an evaluation process for rhodecode. During my test setup it give me a headache that the given nginx example was not working fully in my set up (login and logout were getting a timeout although the user was logged in / out).
After a long search I figured out that the non standard SSL port was the issue. This can easily be fixed by replacng the following in the proxy.conf file (https://docs.rhodecode.com/RhodeCode-Enterprise/admin/nginx-tuning.html) :
replace:
proxy_set_header Host $host;
with:
proxy_set_header Host $host:$server_port;
I hope this helps some other guys in the future ;)
Updated by Marcin Kuzminski [CTO] almost 7 years ago
Hi,
Thanks for the suggestion. We looked at this, and it seem using $http_host instead of $host would solve your problem, and generally would be a safer solution.
This is better than $host:$server_port because it uses the port as present in the URL, unlike $server_port which uses the port that nginx listens on.
Could you confirm this works for you, we'll update our example nginx config then
Updated by Maurice Müller almost 7 years ago
Hi Marcin,
I can confirm that this setup is working as well. Thanks for the suggestion! I'll use this config form now on.
Updated by Marcin Kuzminski [CTO] almost 7 years ago
- Status changed from New to Resolved
Thanks for confirmation. Closing this one.
Updated by Marcin Kuzminski [CTO] about 6 years ago
- Project changed from 7 to Documentation