From f1576eabb1785d780a7f45df0dce650e8adee8c4 Mon Sep 17 00:00:00 2001 From: Etienne Champetier Date: Thu, 21 Jan 2021 23:39:26 -0500 Subject: [PATCH] Calico: fixup check when ipipMode / vxlanMode is not present (#7195) calicoctl.sh get ipPool default-pool -o json { "kind": "IPPool", "apiVersion": "projectcalico.org/v3", "metadata": { "name": "default-pool", ... }, "spec": { "cidr": "10.233.64.0/18", "ipipMode": "Always", "natOutgoing": true, "blockSize": 24, "nodeSelector": "all()" } } Signed-off-by: Etienne Champetier --- roles/network_plugin/calico/tasks/check.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/roles/network_plugin/calico/tasks/check.yml b/roles/network_plugin/calico/tasks/check.yml index 1acb852ac..78e4cb881 100644 --- a/roles/network_plugin/calico/tasks/check.yml +++ b/roles/network_plugin/calico/tasks/check.yml @@ -55,8 +55,8 @@ that: - calico_pool_conf.spec.blockSize == (calico_pool_blocksize | default(kube_network_node_prefix)) - calico_pool_conf.spec.cidr == (calico_pool_cidr | default(kube_pods_subnet)) - - calico_pool_conf.spec.ipipMode == calico_ipip_mode - - calico_pool_conf.spec.vxlanMode == calico_vxlan_mode + - not calico_pool_conf.spec.ipipMode is defined or calico_pool_conf.spec.ipipMode == calico_ipip_mode + - not calico_pool_conf.spec.vxlanMode is defined or calico_pool_conf.spec.vxlanMode == calico_vxlan_mode msg: "Your inventory doesn't match the current cluster configuration" when: - calico_pool_conf is defined