2727 name: dvcr-secrets
2828 key: salt
2929
30- {{- if eq .Values.virtualization.internal.moduleConfig. dvcr. storage. type " PersistentVolumeClaim" }}
30+ {{- if eq ( .Values.virtualization.internal.moduleConfig | dig " dvcr" " storage" " type" " " ) " PersistentVolumeClaim" }}
3131- name: REGISTRY_STORAGE_FILESYSTEM_ROOTDIRECTORY
3232 value: " /var/lib/registry"
33- {{- else if eq .Values.virtualization.internal.moduleConfig. dvcr. storage. type " ObjectStorage" }}
33+ {{- else if eq ( .Values.virtualization.internal.moduleConfig | dig " dvcr" " storage" " type" " " ) " ObjectStorage" }}
3434 {{- if eq .Values.virtualization.internal.moduleConfig.dvcr.storage.objectStorage.type " S3" }}
3535- name: REGISTRY_STORAGE_S3_REGION
3636 value: " {{ .Values.virtualization.internal.moduleConfig.dvcr.storage.objectStorage.s3.region }}"
5353{{- end }}
5454
5555{{- define " dvcr.envs.garbageCollection" -}}
56- {{- if eq .Values.virtualization.internal.moduleConfig. dvcr. storage. type " PersistentVolumeClaim" }}
56+ {{- if eq ( .Values.virtualization.internal.moduleConfig | dig " dvcr" " storage" " type" " " ) " PersistentVolumeClaim" }}
5757- name: REGISTRY_STORAGE_FILESYSTEM_ROOTDIRECTORY
5858 value: " /var/lib/registry"
5959{{- end }}
6464- name: " dvcr-config"
6565 mountPath: " /etc/docker/registry"
6666
67- {{- if eq .Values.virtualization.internal.moduleConfig. dvcr. storage. type " PersistentVolumeClaim" }}
67+ {{- if eq ( .Values.virtualization.internal.moduleConfig | dig " dvcr" " storage" " type" " " ) " PersistentVolumeClaim" }}
6868- name: data
6969 mountPath: /var/lib/registry/
7070{{- end }}
8282{{- define " dvcr.volumeMounts.garbageCollection" -}}
8383- name: " dvcr-config"
8484 mountPath: " /etc/docker/registry"
85- {{- if eq .Values.virtualization.internal.moduleConfig. dvcr. storage. type " PersistentVolumeClaim" }}
85+ {{- if eq ( .Values.virtualization.internal.moduleConfig | dig " dvcr" " storage" " type" " " ) " PersistentVolumeClaim" }}
8686- name: data
8787 mountPath: /var/lib/registry/
8888{{- end }}
9494 configMap:
9595 name: dvcr-config
9696
97- {{- if eq .Values.virtualization.internal.moduleConfig. dvcr. storage. type " PersistentVolumeClaim" }}
97+ {{- if eq ( .Values.virtualization.internal.moduleConfig | dig " dvcr" " storage" " type" " " ) " PersistentVolumeClaim" }}
9898- name: data
9999 persistentVolumeClaim:
100100 claimName: dvcr
@@ -118,18 +118,18 @@ true
118118replicas: 1
119119strategy:
120120 type: Recreate
121- {{- else if and (include " helm_lib_ha_enabled" . ) (eq .Values.virtualization.internal.moduleConfig. dvcr. storage. type " ObjectStorage" ) }}
121+ {{- else if and (include " helm_lib_ha_enabled" . ) (eq ( .Values.virtualization.internal.moduleConfig | dig " dvcr" " storage" " type" " " ) " ObjectStorage" ) }}
122122replicas: 2
123123strategy:
124124 type: RollingUpdate
125125 rollingUpdate:
126126 maxSurge: 0
127127 maxUnavailable: 1
128- {{- else if eq .Values.virtualization.internal.moduleConfig. dvcr. storage. type " ObjectStorage" }}
128+ {{- else if eq ( .Values.virtualization.internal.moduleConfig | dig " dvcr" " storage" " type" " " ) " ObjectStorage" }}
129129replicas: 1
130130strategy:
131131 type: RollingUpdate
132- {{- else if eq .Values.virtualization.internal.moduleConfig. dvcr. storage. type " PersistentVolumeClaim" }}
132+ {{- else if eq ( .Values.virtualization.internal.moduleConfig | dig " dvcr" " storage" " type" " " ) " PersistentVolumeClaim" }}
133133replicas: 1
134134strategy:
135135 type: Recreate
@@ -140,7 +140,7 @@ strategy:
140140 {{- $context := index . 0 -}}
141141 {{- $yes := index . 1 -}}
142142 {{- $no := index . 2 -}}
143- {{- if and (include " helm_lib_ha_enabled" $context ) (eq $context .Values.virtualization.internal.moduleConfig. dvcr. storage. type " ObjectStorage" ) }}
143+ {{- if and (include " helm_lib_ha_enabled" $context ) (eq ( $context .Values.virtualization.internal.moduleConfig | dig " dvcr" " storage" " type" " " ) " ObjectStorage" ) }}
144144 {{- $yes -}}
145145 {{- else }}
146146 {{- $no -}}
0 commit comments