Nginx reverser proxy error in configuration template

Hi: I have been following the steps at regarding the reverse proxy configuration using nginx. The configuration that is shown at that URL is:
location /jupyter/ {
# NOTE important to also set base url of jupyterhub to /jupyter in its config

proxy_redirect   off;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header Host $host;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;

# websocket headers
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection $connection_upgrade;

If you try this and check it by means of “nginx -t” you’ll see an error regarding “proxy_set_header Connection $connection_upgrade;” indicating that $connection_upgrade can not be found.

I have seen that in the following link you can find the right way to declare that sentence as mentioned in by @willingc.

I think that this should be amended in the documentation page.

Best regards,


Hi, this is the reverse proxy documentation that I know and it has a full working example of nginx configuration. Mabe Install JupyterHub and JupyterLab from the ground up should reference to it for nginx configuration part.

Hi: Thank you @bitnik. Anyway, if you follow the instructions at by @willingc it also works.