From 2f75e7e089dd96f0412f0327cf21d3697e01f261 Mon Sep 17 00:00:00 2001 From: pingcap-github-bot Date: Wed, 11 Mar 2020 09:34:17 +0800 Subject: [PATCH] fix operator failover config invalid (#1902) Co-authored-by: mikechengwei <842725815@qq.com> --- .../templates/controller-manager-deployment.yaml | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/charts/tidb-operator/templates/controller-manager-deployment.yaml b/charts/tidb-operator/templates/controller-manager-deployment.yaml index a4958585116..9aead4e806c 100644 --- a/charts/tidb-operator/templates/controller-manager-deployment.yaml +++ b/charts/tidb-operator/templates/controller-manager-deployment.yaml @@ -38,7 +38,12 @@ spec: {{- end }} - -tidb-discovery-image={{ .Values.operatorImage }} - -cluster-scoped={{ .Values.clusterScoped }} - - -auto-failover={{ .Values.controllerManager.autoFailover | default true }} + {{- if eq .Values.controllerManager.autoFailover true }} + - -auto-failover=true + {{- end }} + {{- if eq .Values.controllerManager.autoFailover false }} + - -auto-failover=false + {{- end }} - -pd-failover-period={{ .Values.controllerManager.pdFailoverPeriod | default "5m" }} - -tikv-failover-period={{ .Values.controllerManager.tikvFailoverPeriod | default "5m" }} - -tidb-failover-period={{ .Values.controllerManager.tidbFailoverPeriod | default "5m" }}