c.KubeSpawner not respecting storage values

Hey everyone,

I’m using both Helm chart configs and extra configs to pass information to the hub.

In my values.yaml file:

# ...

singleuser:
  storage:
    type: dynamic
    capacity: 10Gi
    dynamic:
      storageClass: jupyterhub
      pvcNameTemplate: claim-{username}-{servername}
      volumeNameTemplate: volume-{username}-{servername}
# ...

The PVC name is still being templated as the default value, claim-{username}{servername}.

I’ve tried to configure this via extra config:

# ...
hub:
  extraConfig:
    myConfig.py: |
      c.KubeSpawner.pvc_name_template = 'claim-{username}-{servername}'
      c.KubeSpawner.storage_pvc_ensure = True
      c.KubeSpawner.storage_class = 'jupyterhub'
      c.KubeSpawner.storage_access_modes = [
        'ReadWriteOnce',
      ]
      c.KubeSpawner.storage_capacity = '20Gi'
      c.KubeSpawner.volumes = [
        {
          'name': 'volume-{username}-{servername}',
          'persistentVolumeClaim': {
            'claimName': 'claim-{username}-{servername}',
          }
        }
      ]
      c.KubeSpawner.volume_mounts = [
        {
          'name': 'volume-{username}-{servername}',
          'mountPath': '/home/jovyan'
        }
      ]
# ...

I’m still getting the default values for the name and the capacity.

Any ideias?

I’ve also tried to configure this in c.KubeSpawner.auth_state_hook and c.KubeSpawner.pre_spawn_hook, both unsuccessful too.