diff --git a/deploy/charts/cert-manager/templates/cainjector-deployment.yaml b/deploy/charts/cert-manager/templates/cainjector-deployment.yaml index 79ead56d8..fe09c279c 100644 --- a/deploy/charts/cert-manager/templates/cainjector-deployment.yaml +++ b/deploy/charts/cert-manager/templates/cainjector-deployment.yaml @@ -16,8 +16,8 @@ metadata: {{- end }} spec: replicas: {{ .Values.cainjector.replicaCount }} - {{- if .Values.revisionHistoryLimit }} - revisionHistoryLimit: {{ .Values.revisionHistoryLimit }} + {{- if ne (quote .Values.global.revisionHistoryLimit) (quote "") }} + revisionHistoryLimit: {{ .Values.global.revisionHistoryLimit }} {{- end }} selector: matchLabels: diff --git a/deploy/charts/cert-manager/templates/deployment.yaml b/deploy/charts/cert-manager/templates/deployment.yaml index 69be7213b..f13df1f66 100644 --- a/deploy/charts/cert-manager/templates/deployment.yaml +++ b/deploy/charts/cert-manager/templates/deployment.yaml @@ -15,8 +15,8 @@ metadata: {{- end }} spec: replicas: {{ .Values.replicaCount }} - {{- if .Values.revisionHistoryLimit }} - revisionHistoryLimit: {{ .Values.revisionHistoryLimit }} + {{- if ne (quote .Values.global.revisionHistoryLimit) (quote "") }} + revisionHistoryLimit: {{ .Values.global.revisionHistoryLimit }} {{- end }} selector: matchLabels: diff --git a/deploy/charts/cert-manager/templates/webhook-deployment.yaml b/deploy/charts/cert-manager/templates/webhook-deployment.yaml index 4bc3b51be..c010ba160 100644 --- a/deploy/charts/cert-manager/templates/webhook-deployment.yaml +++ b/deploy/charts/cert-manager/templates/webhook-deployment.yaml @@ -15,8 +15,8 @@ metadata: {{- end }} spec: replicas: {{ .Values.webhook.replicaCount }} - {{- if .Values.revisionHistoryLimit }} - revisionHistoryLimit: {{ .Values.revisionHistoryLimit }} + {{- if ne (quote .Values.global.revisionHistoryLimit) (quote "") }} + revisionHistoryLimit: {{ .Values.global.revisionHistoryLimit }} {{- end }} selector: matchLabels: diff --git a/deploy/charts/cert-manager/values.yaml b/deploy/charts/cert-manager/values.yaml index 2ced298a0..def133b88 100644 --- a/deploy/charts/cert-manager/values.yaml +++ b/deploy/charts/cert-manager/values.yaml @@ -17,6 +17,9 @@ global: commonLabels: {} # team_name: dev + # The number of old ReplicaSets to retain to allow rollback (If not set, default Kubernetes value is set to 10) + # revisionHistoryLimit: 1 + # Optional priority class to be used for the cert-manager pods priorityClassName: "" rbac: @@ -54,9 +57,6 @@ installCRDs: false replicaCount: 1 -# Number of old history to retain to allow rollback (If not set, default Kubernetes value is set to 10) -# revisionHistoryLimit: 1 - strategy: {} # type: RollingUpdate # rollingUpdate: