We’ve just setup a new k8 cluster and our ingress controller is Contour.
I got vanilla jhub working just fine.
Now using the bitnami jupyter hub charts etc.
Now trying to integrate it with contour so we can have the /jhub etc.
Setting up httpproxy’s is just fine.
The issue is that when we try to set the base_url to jhub, the hub wont fully come up.
In the log I’m seeing
[I 2022-08-18 15:31:54.495 JupyterHub proxy:347] Checking routes
[I 2022-08-18 15:32:03.804 JupyterHub log:189] 302 GET /jhub/hub/health → /hub/jhub/hub/health (@172.20.6.1) 0.67ms
[W 2022-08-18 15:32:03.805 JupyterHub log:189] 404 GET /hub/jhub/hub/health (@172.20.6.1) 1.06ms
I dont understand…
What does the I/W at start of line mean? Guessing its Info/Warning??
What is this /jhub/hub/health → /hub/jhub/hub/health and why is it doing it?
/jhub/hub/health exists
/hub/jhub/hub/health doesnt… So why / what is it doing it and how do I stop it (what property etc in the chart is causing this and how can I prevent it)
Any help would be great (especially if someone has used Contour and/or Bitnami installation)
This redirect occurs because the Hub’s base URL is not/jhub/. Can you share how you are setting the base url and the startup logs from the hub pod (up to at least JupyterHub is now running at http...)?
I did set the hub.baseUrl which should set the baseUrl property in the hub which results in “/jhub/hub/health” but then it tries to do “/hub/jhub/hub/health” .
I have raise this a chart issue with bitnami but I also trying to see if I could at least figure out where the issue might lie so I could figure it out myself.
If I run it from a native jhub install via helm it works just fine using the baseUrl property…
This log shows that the base_url parameter is not being set (This logged URL is http://{hub_host}{base_url}hub/ so base_url is /). I’m not sure how the bitnami charts expose this option, or if they do, but it seems to be a question for the maintainers of those charts.
The config you want to set is c.JupyterHub.base_url = "...", but other parts of the chart likely need to be aware of this to work (health checks, etc.).
spot on!!
Turns out that in their values.yaml file, they build a configuration and then save it as a secret which the hub then reads.
The baseUrl was missing from it.
I’ve requested bitnami patch that file and it should work in the future.
Thanks for the insight…