2017-09-04 08:29:51 +00:00
|
|
|
---
|
|
|
|
- name: Start Calico resources
|
|
|
|
kube:
|
2019-05-02 21:24:21 +00:00
|
|
|
name: "{{ item.item.name }}"
|
2018-03-30 11:29:13 +00:00
|
|
|
namespace: "kube-system"
|
2019-05-02 21:24:21 +00:00
|
|
|
kubectl: "{{ bin_dir }}/kubectl"
|
|
|
|
resource: "{{ item.item.type }}"
|
|
|
|
filename: "{{ kube_config_dir }}/{{ item.item.file }}"
|
2017-09-05 05:23:12 +00:00
|
|
|
state: "latest"
|
2019-04-23 17:37:23 +00:00
|
|
|
with_items:
|
|
|
|
- "{{ calico_node_manifests.results }}"
|
2019-04-25 12:00:48 +00:00
|
|
|
- "{{ calico_node_kdd_manifest.results }}"
|
|
|
|
- "{{ calico_node_typha_manifest.results }}"
|
2018-08-23 14:17:18 +00:00
|
|
|
when:
|
2019-04-23 17:37:23 +00:00
|
|
|
- inventory_hostname == groups['kube-master'][0] and not item is skipped
|
|
|
|
loop_control:
|
|
|
|
label: "{{ item.item.file }}"
|
2018-08-23 14:17:18 +00:00
|
|
|
|
|
|
|
- name: "calico upgrade complete"
|
|
|
|
shell: "{{ bin_dir }}/calico-upgrade complete --no-prompts --apiconfigv1 /etc/calico/etcdv2.yml --apiconfigv3 /etc/calico/etcdv3.yml"
|
|
|
|
when:
|
|
|
|
- inventory_hostname == groups['kube-master'][0]
|
2018-09-06 12:49:06 +00:00
|
|
|
- calico_upgrade_enabled|default(True)
|
2018-08-23 14:17:18 +00:00
|
|
|
- calico_upgrade_needed|default(False)
|