diff --git a/charts/descheduler/templates/NOTES.txt b/charts/descheduler/templates/NOTES.txt index 1ea9cb525..588298048 100644 --- a/charts/descheduler/templates/NOTES.txt +++ b/charts/descheduler/templates/NOTES.txt @@ -1,7 +1,7 @@ Descheduler installed as a {{ .Values.kind }}. {{- if eq .Values.kind "Deployment" }} -{{- if eq .Values.replicas 1 }} +{{- if eq (.Values.replicas | int) 1 }} WARNING: You set replica count as 1 and workload kind as Deployment however leaderElection is not enabled. Consider enabling Leader Election for HA mode. {{- end}} {{- if .Values.leaderElection }} diff --git a/charts/descheduler/templates/deployment.yaml b/charts/descheduler/templates/deployment.yaml index 67b0d29de..85688eec6 100644 --- a/charts/descheduler/templates/deployment.yaml +++ b/charts/descheduler/templates/deployment.yaml @@ -7,7 +7,7 @@ metadata: labels: {{- include "descheduler.labels" . | nindent 4 }} spec: - {{- if gt .Values.replicas 1 }} + {{- if gt (.Values.replicas | int) 1 }} {{- if not .Values.leaderElection.enabled }} {{- fail "You must set leaderElection to use more than 1 replica"}} {{- end}}