kubeadm_discovery_address should not contain proto (#4930)
This commit is contained in:
parent
f599c2a691
commit
c7f3123e28
6 changed files with 10 additions and 10 deletions
|
@ -5,7 +5,7 @@
|
|||
{%- if "127.0.0.1" in kube_apiserver_endpoint or "localhost" in kube_apiserver_endpoint -%}
|
||||
{{ first_kube_master }}:{{ kube_apiserver_port }}
|
||||
{%- else -%}
|
||||
{{ kube_apiserver_endpoint }}
|
||||
{{ kube_apiserver_endpoint | replace("https://", "") }}
|
||||
{%- endif %}
|
||||
tags:
|
||||
- facts
|
||||
|
@ -119,7 +119,7 @@
|
|||
when:
|
||||
- kubeadm_config_api_fqdn is not defined
|
||||
- not is_kube_master
|
||||
- kubeadm_discovery_address != kube_apiserver_endpoint
|
||||
- kubeadm_discovery_address != kube_apiserver_endpoint | replace("https://", "")
|
||||
notify: restart kubelet
|
||||
|
||||
- name: Update server field in kube-proxy kubeconfig
|
||||
|
@ -131,7 +131,7 @@
|
|||
when:
|
||||
- inventory_hostname == groups['kube-master']|first
|
||||
- kubeadm_config_api_fqdn is not defined
|
||||
- kubeadm_discovery_address != kube_apiserver_endpoint
|
||||
- kubeadm_discovery_address != kube_apiserver_endpoint | replace("https://", "")
|
||||
- not kube_proxy_remove
|
||||
tags:
|
||||
- kube-proxy
|
||||
|
@ -142,7 +142,7 @@
|
|||
when:
|
||||
- inventory_hostname == groups['kube-master']|first
|
||||
- kubeadm_config_api_fqdn is not defined
|
||||
- kubeadm_discovery_address != kube_apiserver_endpoint
|
||||
- kubeadm_discovery_address != kube_apiserver_endpoint | replace("https://", "")
|
||||
- not kube_proxy_remove
|
||||
tags:
|
||||
- kube-proxy
|
||||
|
@ -166,7 +166,7 @@
|
|||
when:
|
||||
- inventory_hostname == groups['kube-master']|first
|
||||
- kube_proxy_remove
|
||||
- kubeadm_discovery_address != kube_apiserver_endpoint
|
||||
- kubeadm_discovery_address != kube_apiserver_endpoint | replace("https://", "")
|
||||
tags:
|
||||
- kube-proxy
|
||||
|
||||
|
|
|
@ -6,7 +6,7 @@ discoveryTokenAPIServers:
|
|||
{% if kubeadm_config_api_fqdn is defined %}
|
||||
- {{ kubeadm_config_api_fqdn }}:{{ loadbalancer_apiserver.port | default(kube_apiserver_port) }}
|
||||
{% else %}
|
||||
- {{ kubeadm_discovery_address | replace("https://", "")}}
|
||||
- {{ kubeadm_discovery_address }}
|
||||
{% endif %}
|
||||
discoveryTokenCACertHashes:
|
||||
- sha256:{{ kubeadm_ca_hash.stdout }}
|
||||
|
|
|
@ -11,7 +11,7 @@ discoveryTokenAPIServers:
|
|||
{% if kubeadm_config_api_fqdn is defined %}
|
||||
- {{ kubeadm_config_api_fqdn }}:{{ loadbalancer_apiserver.port | default(kube_apiserver_port) }}
|
||||
{% else %}
|
||||
- {{ kubeadm_discovery_address | replace("https://", "")}}
|
||||
- {{ kubeadm_discovery_address }}
|
||||
{% endif %}
|
||||
discoveryTokenUnsafeSkipCAVerification: true
|
||||
nodeRegistration:
|
||||
|
|
|
@ -11,7 +11,7 @@ discoveryTokenAPIServers:
|
|||
{% if kubeadm_config_api_fqdn is defined %}
|
||||
- {{ kubeadm_config_api_fqdn }}:{{ loadbalancer_apiserver.port | default(kube_apiserver_port) }}
|
||||
{% else %}
|
||||
- {{ kubeadm_discovery_address | replace("https://", "")}}
|
||||
- {{ kubeadm_discovery_address }}
|
||||
{% endif %}
|
||||
discoveryTokenUnsafeSkipCAVerification: true
|
||||
nodeRegistration:
|
||||
|
|
|
@ -6,7 +6,7 @@ discovery:
|
|||
{% if kubeadm_config_api_fqdn is defined %}
|
||||
apiServerEndpoint: {{ kubeadm_config_api_fqdn }}:{{ loadbalancer_apiserver.port | default(kube_apiserver_port) }}
|
||||
{% else %}
|
||||
apiServerEndpoint: {{ kubeadm_discovery_address | replace("https://", "")}}
|
||||
apiServerEndpoint: {{ kubeadm_discovery_address }}
|
||||
{% endif %}
|
||||
token: {{ kubeadm_token }}
|
||||
caCertHashes:
|
||||
|
|
|
@ -5,7 +5,7 @@ discovery:
|
|||
{% if kubeadm_config_api_fqdn is defined %}
|
||||
apiServerEndpoint: {{ kubeadm_config_api_fqdn }}:{{ loadbalancer_apiserver.port | default(kube_apiserver_port) }}
|
||||
{% else %}
|
||||
apiServerEndpoint: {{ kubeadm_discovery_address | replace("https://", "")}}
|
||||
apiServerEndpoint: {{ kubeadm_discovery_address }}
|
||||
{% endif %}
|
||||
token: {{ kubeadm_token }}
|
||||
unsafeSkipCAVerification: true
|
||||
|
|
Loading…
Reference in a new issue