aenix-io / etcd-operator

New generation community-driven etcd-operator!
https://etcd.aenix.io
Apache License 2.0
83 stars 14 forks source link

Enable resize operation #210

Closed kvaps closed 1 month ago

kvaps commented 3 months ago

phase1:

if .spec.storage.volumeClaimTemplate.spec.resources.requestes.storage updated:

  storage:
    volumeClaimTemplate:
      metadata: {}
      spec:
        accessModes:
        - ReadWriteOnce
        resources:
          requests:
            storage: 20Gi

then delete statefulset with --cascade=orphan and create a new one

phase2:

Loop over all PVCs

if storageClass has allowVolumeExpansion: true

then patch PVC object to higher size

spec:
  resources:
    requests:
      storage: 20Gi