diff --git a/library/common/Chart.yaml b/library/common/Chart.yaml index 4ec61db08..96f6c15b8 100644 --- a/library/common/Chart.yaml +++ b/library/common/Chart.yaml @@ -15,7 +15,7 @@ maintainers: name: common sources: null type: library -version: 22.0.2 +version: 22.0.3 annotations: artifacthub.io/category: "integration-delivery" artifacthub.io/license: "BUSL-1.1" diff --git a/library/common/templates/class/volsync/_replicationDestination.tpl b/library/common/templates/class/volsync/_replicationDestination.tpl index 95516c008..74a39ac56 100644 --- a/library/common/templates/class/volsync/_replicationDestination.tpl +++ b/library/common/templates/class/volsync/_replicationDestination.tpl @@ -38,8 +38,12 @@ spec: {{ $volsyncData.type }}: repository: {{ $volsyncData.repository }} copyMethod: {{ $volsyncData.copyMethod | default "Snapshot"}} - {{- with $volsyncData.dest.capacity }} + {{- if $volsyncData.dest.capacity }} capacity: {{ $volsyncData.dest.capacity }} + {{- else if $objectData.size }} + capacity: {{ $objectData.size }} + {{- else }} + capacity: {{ $rootCtx.Values.global.fallbackDefaults.pvcSize }} {{- end }} {{- include "tc.v1.common.lib.volsync.storage" (dict "rootCtx" $rootCtx "objectData" $objectData "volsyncData" $volsyncData "target" "dest") | trim | nindent 4 }} diff --git a/library/common/templates/lib/volsync/_storage.tpl b/library/common/templates/lib/volsync/_storage.tpl index f9f34395c..b24f49623 100644 --- a/library/common/templates/lib/volsync/_storage.tpl +++ b/library/common/templates/lib/volsync/_storage.tpl @@ -10,9 +10,18 @@ storageClassName: {{ . }} {{- end -}} - {{- with $target.accessModes }} accessModes: - {{- range . }} + {{- if $target.accessModes }} + + {{- range $target.accessModes }} + - {{ . }} + {{- end }} + {{- else if $objectData.accessModes }} + {{- range $objectData.accessModes }} + - {{ . }} + {{- end }} + {{- else }} + {{- range $rootCtx.Values.global.fallbackDefaults.accessModes }} - {{ . }} {{- end }} {{- end -}}