hi, I’m deploying jupyterhub on Kubernetes cluster with the helm chart,
I’m using custom pre_spawn_hook to determine the namespace-
in my conf.py file:
async def custom_pre_spawn_hook(spawner):
if :
spawner.namespace = namespce_1
else:
spawner.namespace = namespce_2
c.kubespawner.pre_spawn_hook = custom_pre_spawn_hook
with this configuration the pod is spawn successfully on the other namespace but the hub don’t get the pod and in the ui I’m stack on state of server quested with no events.
when I’m changing the value of c.kubespawner.namespce to the wanted namespace its working.
what is the difference between the spawner.namespace inside the custom_pre_spawn_hook and the c.kubespawner.namespce. and how can i change it dynamically?