kubernetes - What would be an ideal way to share writable volume across containers for a web server? -


the application in question wordpress, need create replicas rolling deployment / scaling purposes.

it seem can't create more 1 instance of same container, if uses persistent volume (gcp term):

the deployment "wordpress" invalid: spec.template.spec.volumes[0].gcepersistentdisk.readonly: invalid value: false: must true replicated pods > 1; gce pd can mounted on multiple machines if read-only 

what options? there occasional writes , many reads. ideally writable containers. i'm hesitant use network file systems i'm not sure whether they'll provide sufficient performance web application (where page load rather critical).

one idea have is, create master container (write , read permission) , slaves (read permission), work - i'll need figure out kubernetes configuration required.

in https://kubernetes.io/docs/concepts/storage/persistent-volumes/#persistent-volumes can see table possible storage classes allow readwritemany (the option looking for).

  • azurefile (not suitable if using gcp)
  • cephfs
  • glusterfs
  • quobyte
  • nfs
  • portworxvolume

the 1 i've tried of nfs. had no issues it, guess should consider potential performance issues. however, if writes occassional, shouldn't of issue.


Comments

Popular posts from this blog

android - InAppBilling registering BroadcastReceiver in AndroidManifest -

python Tkinter Capturing keyboard events save as one single string -

sql server - Why does Linq-to-SQL add unnecessary COUNT()? -