KubeADM: force calico interface to match to same as kubelet

This PS forces calico to use the same interface as the kubelet
for inter-node communication.

Change-Id: I7d03beec46cccba4a57e092bf108695e8e88996f
This commit is contained in:
Pete Birley 2018-03-08 18:54:59 +00:00
parent d6e9fa2c5a
commit c9ffaea770

@ -63,7 +63,7 @@
environment:
KUBECONFIG: '/mnt/rootfs/etc/kubernetes/admin.conf'
- name: kubeadm | cni | calico
command: helm install /opt/charts/calico --name calico --namespace kube-system --set networking.podSubnet="{{ k8s.networking.podSubnet }}" --set networking.mtu="{{ cni_default_device_mtu.stdout }}" --wait --timeout=600
command: helm install /opt/charts/calico --name calico --namespace kube-system --set networking.podSubnet="{{ k8s.networking.podSubnet }}" --set conf.node.IP_AUTODETECTION_METHOD="can-reach={% if k8s.api.advertiseAddress is defined %}{{ k8s.api.advertiseAddress }}{% else %}{% if k8s.api.advertiseAddressDevice is defined %}{{ hostvars[inventory_hostname]['ansible_'+k8s.api.advertiseAddressDevice].ipv4.address }}{% else %}{{ hostvars[inventory_hostname]['ansible_default_ipv4']['address'] }}{% endif %}{% endif %}" --set networking.mtu="{{ cni_default_device_mtu.stdout }}" --wait --timeout=600
environment:
HELM_HOST: 'localhost:44134'
- name: kubeadm | cni | calico