-
Couldn't load subscription status.
- Fork 287
Closed
Description
What happened: if subDir is set to something like foo/${pvc.metadata.namespace}/${pvc.metadata.name}/ and if there are no more PVCs left in a given namespace, all data under /foo will be deleted.
What you expected to happen: This is arguably caused by bad config since something like subDir=${pvc.metadata.namespace}/${pvc.metadata.name}/ would prevent the issue. But still, would be nice to have this highlighted in the docs at least.
I think the issue is caused here specifically by getRootDir.
How to reproduce it:
- Create a default storage class with
subDir=foo/${pvc.metadata.namespace}/${pvc.metadata.name} - Create something with a PVC (a database for example) in two different namespaces
- Deleting PVCs in one namespace should delete all data
Anything else we need to know?:
Environment:
- CSI Driver version: 4.10
- Kubernetes version (use
kubectl version): v1.31.2+rke2r1 - OS (e.g. from /etc/os-release): Ubuntu 24.04 LTS
- Kernel (e.g.
uname -a): 6.8.0-31-generic
blackliner, rgelsi, UnknownAtoms and ralite
Metadata
Metadata
Assignees
Labels
No labels