using ip address instead of inventory_hostname for kube-proxy
parent
b3841659d7
commit
9914229484
|
@ -18,7 +18,7 @@ spec:
|
|||
{% if loadbalancer_apiserver is defined and apiserver_loadbalancer_domain_name is defined %}
|
||||
- --master=https://{{ apiserver_loadbalancer_domain_name }}:{{ loadbalancer_apiserver.port }}
|
||||
{% else %}
|
||||
- --master=https://{{ groups['kube-master'][0] }}:{{ kube_apiserver_port }}
|
||||
- --master=https://{{ hostvars[groups['kube-master'][0]]['ip'] | default(hostvars[groups['kube-master'][0]]['ansible_default_ipv4']['address']) }}:{{ kube_apiserver_port }}
|
||||
{% endif%}
|
||||
- --kubeconfig=/etc/kubernetes/node-kubeconfig.yaml
|
||||
{% endif %}
|
||||
|
|
Loading…
Reference in New Issue