46c177b982
For consistancy with kubernetes services we should use the same hostname for nodes, which is 'ansible_hostname'. Also fixing missed 'kube-node' in templates, Calico is installed on 'k8s-cluster' roles, not only 'kube-node'.
15 lines
609 B
Django/Jinja
15 lines
609 B
Django/Jinja
ETCD_ENDPOINTS="{{ etcd_access_endpoint }}"
|
|
ETCD_CA_CERT_FILE="{{ calico_cert_dir }}/ca_cert.crt"
|
|
ETCD_CERT_FILE="{{ calico_cert_dir }}/cert.crt"
|
|
ETCD_KEY_FILE="{{ calico_cert_dir }}/key.pem"
|
|
CALICO_IP="{{ip | default(ansible_default_ipv4.address) }}"
|
|
CALICO_IP6=""
|
|
{% if calico_network_backend is defined %}
|
|
CALICO_NETWORKING_BACKEND="{{calico_network_backend }}"
|
|
{% endif %}
|
|
{% if inventory_hostname in groups['k8s-cluster'] and peer_with_router|default(false)%}
|
|
CALICO_AS="{{ local_as }}"
|
|
{% endif %}
|
|
CALICO_NO_DEFAULT_POOLS="true"
|
|
CALICO_LIBNETWORK_ENABLED="true"
|
|
CALICO_HOSTNAME="{{ ansible_hostname }}"
|