Is it possible to allow dynamic PV creation for a static NFS share?
See original GitHub issueHey there!
I’ve been trying to suss this out from the documentation but I have to admit my brain is a bit mushy after doing so (not your fault, just trying to mentally juggle all of the relevant parts) and figured it might be simplest to just ask:
Is it possible to create a storage class for dynamic PV/PVC provisioning that can use an existing NFS export/share?
My goal essentially boils down to wanting to do what node-manual
seems to be more or less designed for, but entirely with a statically-configured StorageClass
such that I can simply create PersistentVolumeClaim
resources and get the normal dynamic provisioning of PVs on-the-fly. I have a few fixed NFS exports (shared media, general data, yadda yadda) that I want to expose uniformly to various containers, and for my own (perhaps over-the-top) desire for concise, I’d love to avoid having to bake the PV manually for each of those locations. It just feels weird to have to do that.
Issue Analytics
- State:
- Created a year ago
- Comments:6 (3 by maintainers)
Yeah, fair enough.
I mostly just wasn’t sure if there was an existing way to push the CSI configuration, when using the
node-manual
driver, from the PV itself to a storage class that could be used dynamically.Appreciate the response/rubber ducking. 👍🏻
OK, it doesn’t really make sense to include something of that nature in this project (it is arguably very niche). However, leveraging the
node-manual
features you could fairly easily create your own ‘operator’ (effectively storage class) to achieve this goal.The idea is the operator would watch select PVCs and create PVs that adhere to the
node-manual
syntax in an automated fashion.https://github.com/flant/shell-operator
A little shell mixed with
kubectl
(in the shell script) would likely be pretty quick.