Changing singleuser.storage.type

Hello, members

1. Questions

Currently, there is the z2jh environment with singleuser.storage.type: dynamic.
When I change the configuration to singleuser.storage.type: static,
do I need to remove the current z2jh environment using helm delete jhub -n ns-z2jh?
Or, Is it possible to change the configuration only?
(Now I delete the z2jh environment. then re-create z2jh with a new configuration.)

Best regards.

2. Environment

  • OS: Ubuntu 22.04
  • Helm: v3.12.3
  • Kubernetes: v1.27.4 (Self-Hosted)
  • Z2JH: 3.0.2

3. Creating environment.

helm upgrade --cleanup-on-fail \
  --install jhub jupyterhub/jupyterhub \
  --namespace ns-z2jh \
  --create-namespace \
  --version=3.0.2 \
  --values config.yaml
custom:
  hoge: foo
hub:
  db:
    pvc:
      storageClassName: nfs-client
debug:
  enabled: true
singleuser:
  storage:
    capacity: 100Mi
    homeMountPath: /home/jovyan
    dynamic:
      pvcNameTemplate: claim-{username}{servername}
      storageAccessModes:
      - ReadWriteMany
      storageClass: nfs-client
      volumeNameTemplate: volume-{username}{servername}
    homeMountPath: /home/jovyan
    type: dynamic

helm upgrade is usually sufficient. Note that old dynamically created volumes probably won’t be deleted, you’ll have to clean them up yourself.

Hello, @manics. Thank you for your reply.

I just execute the same command with the new configuration.

helm upgrade --cleanup-on-fail \
  --install jhub jupyterhub/jupyterhub \
  --namespace ns-z2jh \
  --create-namespace \
  --version=3.0.2 \
  --values new_config.yaml # <-- Use new config

And remove dynamic volume like kubectl delete pv and kubectl delete sc

Is my understanding correct?

Best regards.

I succeed update the configuration with the following command.

helm upgrade jhub jupyterhub/jupyterhub \
  --namespace ns-z2jh \
  --version=3.0.3 \
  --values new-config.yaml

Thanks! @manics