Volume name template

Hi jovyans on k8s,

I have tried setting a value for singleuser.storage.dynamic.volumeNameTemplate as described in the configuration reference. However the names of the dynamically created volumes are not following the template.

Here is a snippet from my config.yaml:

singleuser:
  storage:
      capacity: 5Gi
      dynamic:
        storageClass: jupyterhub-user-ssd
        volumeNameTemplate: volume-{username}

Is the config flawed?

I just hit this same problem using AWS EFS, I think that volumeNameTemplate changes the Volume of the pod as seen by kubernetes, but not the underlying name of the created folder. Volumes | Kubernetes

I was able to get the folder to have the right name with config like this:

singleuser:
  storage:
    type: "static"
    static:
      pvcName: "efs-pvc"
      subPath: "{username}"

Follow on question: is there a drawback to having all users share one PVC instead of doing dynamic?

In our case we have users spawning on distinct phyiscal nodes in the cluster, and most volumes cannot be mounted on several machines at once.