How to set SecurityContext in singleuser pods? (original) (raw)
Hi,
We have a Helm jupyterhub@3.3.7 deployment and we are trying to set singleuser pods with
securityContext:
fsGroup: 100
fsGroupChangePolicy: OnRootMismatch ← This is the important config we need
hub.podSecurityContext just applies to the hub pod. I have also tried hub.config.KubeSpawner as suggested here but the property is not propagated correctly to the pod.
Am I missing something ?
Thanks in advance
Hi,
We could finally solve the issue.
The only way I could find to correctly propagate the kubeSpawner.podSecurityContext
into the singleuser pods was via hub.extraConfig
:
hub:
extraConfig:
custom-securityContex: |
c.KubeSpawner.pod_security_context = {
...
}
Cheers,