From 2ccdebdd4df199531805d1d224ce1be8983608b9 Mon Sep 17 00:00:00 2001 From: mikechengwei <842725815@qq.com> Date: Fri, 6 Mar 2020 21:46:09 +0800 Subject: [PATCH] fix operator failover config invalid --- .../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" }}