As I want to share my PVC with multiple pods I have created a PVC with Readonlymany mode on GKE. Now how to put the data on that disk which all the other pods can use. In the documentation it says that GKE only support Readwriteonce and Readonlymany. So how to put my read-only data on the disk which other pods can use
1 Answers
0
votes
You’ll need to seed the disk with data another way - before you mount it inside your Pods.
- You could create a disk from a snapshot of another disk that you regularly update with the necessary data
- This could be on a VM, or via another Pod that does the work
- Read the docs on ReadOnlyMany - https://cloud.google.com/kubernetes-engine/docs/concepts/persistent-volumes#using_compute_engine_persistent_disks_as_readonlymany
Understanding more about what problem you want to solve will be helpful. If you truly need to write from multiple sources, then using Filestore (NFS) may address that: https://cloud.google.com/community/tutorials/gke-filestore-dynamic-provisioning