Skip to content

Commit

Permalink
fix: avoid nil pointer due to nested values
Browse files Browse the repository at this point in the history
Signed-off-by: Casey Buto <[email protected]>
  • Loading branch information
cbuto committed Dec 8, 2023
1 parent 3a7ec61 commit 8b4510f
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions charts/velero/templates/upgrade-crds/upgrade-crds.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -86,10 +86,10 @@ spec:
volumeMounts:
- mountPath: /tmp
name: crds
{{- if .Values.upgradeCRDsJob.extraVolumeMounts }}
{{- if (.Values.upgradeCRDsJob).extraVolumeMounts }}
{{- toYaml .Values.upgradeCRDsJob.extraVolumeMounts | nindent 12 }}
{{- end }}
{{- if .Values.upgradeCRDsJob.extraEnvVars }}
{{- if (.Values.upgradeCRDsJob).extraEnvVars }}
env:
{{- with .Values.upgradeCRDsJob.extraEnvVars }}
{{- range $key, $value := . }}
Expand All @@ -101,7 +101,7 @@ spec:
volumes:
- name: crds
emptyDir: {}
{{- if .Values.upgradeCRDsJob.extraVolumes }}
{{- if (.Values.upgradeCRDsJob).extraVolumes }}
{{- toYaml .Values.upgradeCRDsJob.extraVolumes | nindent 8 }}
{{- end }}
restartPolicy: OnFailure
Expand Down

0 comments on commit 8b4510f

Please sign in to comment.