Skip to content

Commit

Permalink
Add additional checking for calico rr cluster_id (kubernetes-sigs#11112)
Browse files Browse the repository at this point in the history
Signed-off-by: tu1h <[email protected]>
  • Loading branch information
tu1h authored and dabeck committed May 7, 2024
1 parent e64b03b commit 076be9b
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions roles/network_plugin/calico/tasks/check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -82,11 +82,12 @@
Minimum version is {{ calico_min_version_required }} supported by the previous kubespray release.
But current version is {{ calico_version_on_server.stdout }}.
- name: "Check that cluster_id is set if calico_rr enabled"
- name: "Check that cluster_id is set and a valid IPv4 address if calico_rr enabled"
assert:
that:
- cluster_id is defined
msg: "A unique cluster_id is required if using calico_rr"
- cluster_id is ansible.utils.ipv4
msg: "A unique cluster_id is required if using calico_rr, and it must be a valid IPv4 address"
when:
- peer_with_calico_rr
- inventory_hostname == groups['kube_control_plane'][0]
Expand Down

0 comments on commit 076be9b

Please sign in to comment.