Skip to content

Commit

Permalink
Merge pull request #487 from jkroepke/helmHookAnnotations
Browse files Browse the repository at this point in the history
[velero] Add toggle to disable annotations
  • Loading branch information
qiuming-best authored Aug 8, 2023
2 parents 7d95633 + 198b128 commit 2892f89
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 1 deletion.
2 changes: 1 addition & 1 deletion charts/velero/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ appVersion: 1.11.1
kubeVersion: ">=1.16.0-0"
description: A Helm chart for velero
name: velero
version: 4.3.0
version: 4.4.0
home: https://github.com/vmware-tanzu/velero
icon: https://cdn-images-1.medium.com/max/1600/1*-9mb3AKnKdcL_QD3CMnthQ.png
sources:
Expand Down
2 changes: 2 additions & 0 deletions charts/velero/templates/backupstoragelocation.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,10 @@ metadata:
name: {{ .name | default "default" }}
namespace: {{ $.Release.Namespace }}
annotations:
{{- if $.Values.helmHookAnnotations }}
"helm.sh/hook": post-install,post-upgrade,post-rollback
"helm.sh/hook-delete-policy": before-hook-creation
{{- end }}
labels:
app.kubernetes.io/name: {{ include "velero.name" $ }}
app.kubernetes.io/instance: {{ $.Release.Name }}
Expand Down
2 changes: 2 additions & 0 deletions charts/velero/templates/schedule.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,10 @@ metadata:
{{- if $schedule.annotations }}
{{- toYaml $schedule.annotations | nindent 4 }}
{{- end }}
{{- if $.Values.helmHookAnnotations }}
"helm.sh/hook": post-install,post-upgrade,post-rollback
"helm.sh/hook-delete-policy": before-hook-creation
{{- end }}
labels:
app.kubernetes.io/name: {{ include "velero.name" $ }}
app.kubernetes.io/instance: {{ $.Release.Name }}
Expand Down
2 changes: 2 additions & 0 deletions charts/velero/templates/volumesnapshotlocation.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,10 @@ metadata:
name: {{ .name | default "default" }}
namespace: {{ $.Release.Namespace }}
annotations:
{{- if $.Values.helmHookAnnotations }}
"helm.sh/hook": post-install,post-upgrade,post-rollback
"helm.sh/hook-delete-policy": before-hook-creation
{{- end }}
labels:
app.kubernetes.io/name: {{ include "velero.name" $ }}
app.kubernetes.io/instance: {{ $.Release.Name }}
Expand Down
4 changes: 4 additions & 0 deletions charts/velero/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,10 @@ annotations: {}
# Labels to add to the Velero deployment's. Optional.
labels: {}

# helmHookAnnotations is required to deploy CustomResources after deploying CRDs. If you manage your CRDs outside of this helm chart
# or using ArgoCD, you are able to disable the helm hooks annotations.
helmHookAnnotations: true

# Annotations to add to the Velero deployment's pod template. Optional.
#
# If using kube2iam or kiam, use the following annotation with your AWS_ACCOUNT_ID
Expand Down

0 comments on commit 2892f89

Please sign in to comment.