Persistent volumes / claims

#1

Hi,

I have a question about persistent volumes / claims.

In the future, I’ll have different clients that create containers on my Kubernetes cluster.
I don’t want to store their personal data like a database for example on the container itself.
I want to store them on my NFS for every unique client.

This would therefore require me to create different persistent volumes (or just different mounting points) per client. Because I don’t want the data of 1000 clients in a single folder, right?

So for every Pod that is being deployed, that holds a container for a client, I want a separate folder/mounting point on my NFS to retain the clients data.

Now, how do I do this?

I suppose I’d need to have the right yaml file to deploy that Pod for the client in such a way, which creates (or specifies) the persistent storage with the designated PVC.

Since the creation of containers is dynamic, I can’t really specify persistent storage with a static name, right?

I got mentally stuck there. How can I solve this problem?

To summarize my intent: I want to store the data for every pod/container in my cluster on my NFS. Preferably a different directory for every container:)

Please help

Sandro