mirror of
https://github.com/kubernetes-sigs/kubespray.git
synced 2025-12-14 13:54:37 +03:00
Determine hyperkube cni to use
Starting from version 1.3.4 of hyperkube, calico is "canalized" which requires flannel and hostonly cni plugins.So we let hyperkube ship necessary cni
This commit is contained in:
@@ -22,6 +22,17 @@
|
|||||||
changed_when: false
|
changed_when: false
|
||||||
notify: restart calico-node
|
notify: restart calico-node
|
||||||
|
|
||||||
|
- name: Calico | Determine hyperkube cni to use depending of the version of kube
|
||||||
|
set_fact:
|
||||||
|
use_hyperkube_cni: >
|
||||||
|
{%- if kube_version | version_compare('v1.3.4','>=') -%}
|
||||||
|
true
|
||||||
|
{%- elif kube_version | version_compare('v1.3.4','<') -%}
|
||||||
|
false
|
||||||
|
{%- else -%}
|
||||||
|
{{ ErrorCannotRecognizeVersion }}
|
||||||
|
{%- endif -%}
|
||||||
|
|
||||||
- name: Calico | Install calico cni bin
|
- name: Calico | Install calico cni bin
|
||||||
command: rsync -piu "{{ local_release_dir }}/calico/bin/calico" "/opt/cni/bin/calico"
|
command: rsync -piu "{{ local_release_dir }}/calico/bin/calico" "/opt/cni/bin/calico"
|
||||||
changed_when: false
|
changed_when: false
|
||||||
|
|||||||
Reference in New Issue
Block a user