Fix path for calico get node names (#1816)

This commit is contained in:
Matthew Mosesohn 2017-10-17 10:54:48 +01:00 committed by GitHub
parent 728d56e74d
commit d4b10eb9f5

View file

@ -8,9 +8,10 @@
- name: Calico | Get kubelet hostname - name: Calico | Get kubelet hostname
shell: >- shell: >-
kubectl get node -o custom-columns='NAME:.metadata.name,INTERNAL-IP:.status.addresses[?(@.type=="InternalIP")].address' {{ bin_dir }}/kubectl get node -o custom-columns='NAME:.metadata.name,INTERNAL-IP:.status.addresses[?(@.type=="InternalIP")].address'
| egrep "[[:space:]]{{ ansible_all_ipv4_addresses | join('[[:space:]]|[[:space:]]') }}[[:space:]]*$" | cut -d" " -f1 | egrep "{{ ansible_all_ipv4_addresses | join('$|') }}$" | cut -d" " -f1
register: calico_kubelet_name register: calico_kubelet_name
delegate_to: "{{ groups['kube-master'][0] }}"
when: cloud_provider is defined when: cloud_provider is defined
- name: Calico | Write Calico cni config - name: Calico | Write Calico cni config