From 15f1b191368bfe920c250d32960e18854ad42ed6 Mon Sep 17 00:00:00 2001 From: stress-t Date: Mon, 1 Mar 2021 22:53:36 +0300 Subject: [PATCH] Fix: added string to bool conversion for use_localhost_as_kube api load balancer (#7324) --- roles/kubespray-defaults/defaults/main.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/roles/kubespray-defaults/defaults/main.yaml b/roles/kubespray-defaults/defaults/main.yaml index ccb1c1bae..fd388b493 100644 --- a/roles/kubespray-defaults/defaults/main.yaml +++ b/roles/kubespray-defaults/defaults/main.yaml @@ -461,7 +461,7 @@ apiserver_loadbalancer_domain_name: "lb-apiserver.kubernetes.local" kube_apiserver_global_endpoint: |- {% if loadbalancer_apiserver is defined -%} https://{{ apiserver_loadbalancer_domain_name }}:{{ loadbalancer_apiserver.port|default(kube_apiserver_port) }} - {%- elif use_localhost_as_kubeapi_loadbalancer is defined -%} + {%- elif use_localhost_as_kubeapi_loadbalancer|default(False)|bool -%} https://127.0.0.1:{{ kube_apiserver_port }} {%- else -%} https://{{ first_kube_master }}:{{ kube_apiserver_port }}