local-path-provisioner
local-path-provisioner copied to clipboard
feat: add support to set folderName on PVC
This makes it possible to set a 'folderName' annotation on a PVC. When set, the name of the created folder on disk will no longer be '$persistentVolumeName_$persistentVolumeClaimNamespace_$persistentVolumeClaimName'. Instead it will be overriden by the value of 'folderName' in the annotation.
It would be great to consider also implement it in the automatic provisioner. Smething like use the namespace of the pvc so the PVs will automatically sorted in folders named by the namespace.
In my scenario I have four k3s-nodes in a lxc container runnig on a proxmox server. They all share one datadir where local-path autoprovision the pvs. This datadir is quit confusing because of the flat use of the volid as the name in that directory.
The path must be validated otherwise it give access to the whole filesystem of the node.
The path must be validated otherwise it give access to the whole filesystem of the node.
Yes, that's right. The (stiatic) basedir must be well validated and the (dynamic) part of the individual subdir-part under teh basedir must be unique, to be safe.
This PR is stale because it has been open 45 days with no activity. Remove stale label or comment or this will be closed in 10 days.
This PR was closed because it has been stalled for 10 days with no activity.