fix: ansible 2.19: calico resources final evaluation (#13503)

The bgp changes are a bit verbose, because I chose to reproduce the
exact semantics of the current code, so that the manifest handed to
calicoctl does not contain unset fields (instead of just using defaults
value).

It would be more readable to just accept default value in the
manifests, but might be a problem if there is other writer of the same
Calico resources.
This commit is contained in:
Max Gautier
2026-09-15 08:55:22 +00:00
committed by GitHub
parent 53a30aea58
commit 5af06acee1
3 changed files with 95 additions and 133 deletions
@@ -32,11 +32,18 @@ calico_cert_dir: /etc/calico/certs
# Global as_num (/calico/bgp/v1/global/as_num)
global_as_num: "64512"
calico_no_global_as_num: false
# TODO : deprecate and use undef() or another invalid value in global_as_num for the same meaning
peer_with_router: false
peer_with_calico_rr: "{{ groups.get('calico_rr', []) != [] }}"
# You can set MTU value here. If left undefined or empty, it will
# not be specified in calico CNI config, so Calico will use built-in
# defaults. The value should be a number, not a string.
# calico_mtu: 1500
calico_advertise_cluster_ips: false
# Advertise Service External IPs
calico_advertise_service_external_ips: []