Add kubeadm controlplaneEndpoint

Nginx LB(default)
Other LB by kubeadm controlplane
This commit is contained in:
rongzhang
2018-08-18 22:05:35 +08:00
parent 3663061b38
commit 59176ebbb9
5 changed files with 25 additions and 4 deletions

View File

@@ -3,6 +3,9 @@ kind: MasterConfiguration
api:
advertiseAddress: {{ ip | default(ansible_default_ipv4.address) }}
bindPort: {{ kube_apiserver_port }}
{% if groups['kube-master'] | length > 1 and kubeadm_config_api_fqdn is defined %}
controlPlaneEndpoint: {{ kubeadm_config_api_fqdn }}
{% endif %}
etcd:
endpoints:
{% for endpoint in etcd_access_addresses.split(',') %}

View File

@@ -3,6 +3,9 @@ kind: MasterConfiguration
api:
advertiseAddress: {{ ip | default(ansible_default_ipv4.address) }}
bindPort: {{ kube_apiserver_port }}
{% if groups['kube-master'] | length > 1 and kubeadm_config_api_fqdn is defined %}
controlPlaneEndpoint: {{ kubeadm_config_api_fqdn }}
{% endif %}
etcd:
external:
endpoints: