diff --git a/charts/kyverno/Chart.yaml b/charts/kyverno/Chart.yaml index 2ec87f0ea0..76ccea3d92 100644 --- a/charts/kyverno/Chart.yaml +++ b/charts/kyverno/Chart.yaml @@ -30,3 +30,5 @@ annotations: description: Support for artifacthub.io/changes annotation - kind: added description: Allow defining imagePullSecrets + - kind: fixed + description: Replica count handling diff --git a/charts/kyverno/templates/NOTES.txt b/charts/kyverno/templates/NOTES.txt index aec28a6cf8..3f3ff67864 100644 --- a/charts/kyverno/templates/NOTES.txt +++ b/charts/kyverno/templates/NOTES.txt @@ -5,7 +5,7 @@ Thank you for installing {{ .Chart.Name }}! Your release is named {{ .Release.Na {{- if not .Values.replicaCount }} ⚠️ WARNING: Setting replicas count below 3 means Kyverno is not running in high availability mode. -{{- else if lt .Values.replicaCount 3 }} +{{- else if lt (int .Values.replicaCount) 3 }} ⚠️ WARNING: Setting replicas count below 3 means Kyverno is not running in high availability mode. {{- end }} diff --git a/charts/kyverno/templates/validate.yaml b/charts/kyverno/templates/validate.yaml index 9d01f729cb..45c03e73a0 100644 --- a/charts/kyverno/templates/validate.yaml +++ b/charts/kyverno/templates/validate.yaml @@ -3,7 +3,7 @@ {{- end }} {{- if .Values.replicaCount }} - {{- if eq .Values.replicaCount 2 }} + {{- if eq (int .Values.replicaCount) 2 }} {{ fail "Kyverno does not support running with 2 replicas. For a highly-available deployment, select 3 replicas or for standalone select 1 replica." }} {{- end }} {{- end }}