diff --git a/inventory/sample/group_vars/k8s_cluster/addons.yml b/inventory/sample/group_vars/k8s_cluster/addons.yml index 51c5dd81ea648de57521dbe7b39a392a8e2da3b1..e7f64ce2e3599896b5c31c8a6add8a23ad02760e 100644 --- a/inventory/sample/group_vars/k8s_cluster/addons.yml +++ b/inventory/sample/group_vars/k8s_cluster/addons.yml @@ -165,7 +165,7 @@ metallb_speaker_enabled: true # metallb_ip_range: # - "10.5.0.50-10.5.0.99" # metallb_pool_name: "loadbalanced" -# matallb_auto_assign: true +# metallb_auto_assign: true # metallb_speaker_nodeselector: # kubernetes.io/os: "linux" # metallb_controller_nodeselector: diff --git a/roles/kubernetes-apps/metallb/defaults/main.yml b/roles/kubernetes-apps/metallb/defaults/main.yml index cd2162e4761c61ac09922381775ac350db797a75..1d2be5301ea935ef766f906e0048cb89ebc68dd0 100644 --- a/roles/kubernetes-apps/metallb/defaults/main.yml +++ b/roles/kubernetes-apps/metallb/defaults/main.yml @@ -19,4 +19,4 @@ metallb_speaker_tolerations: operator: Exists metallb_controller_tolerations: [] metallb_pool_name: "loadbalanced" -matallb_auto_assign: true +metallb_auto_assign: true diff --git a/roles/kubernetes-apps/metallb/tasks/main.yml b/roles/kubernetes-apps/metallb/tasks/main.yml index 952275a8d4ed0e731dc8e67a78239b78c8379cb6..e5920fcc731221d6621f8df2f2bbe409386d4cc4 100644 --- a/roles/kubernetes-apps/metallb/tasks/main.yml +++ b/roles/kubernetes-apps/metallb/tasks/main.yml @@ -18,6 +18,12 @@ - metallb_protocol == 'bgp' and metallb_speaker_enabled - metallb_peers is not defined or not metallb_peers +- name: Kubernetes Apps | Check that the deprecated 'matallb_auto_assign' variable is not used anymore + fail: + msg: "'matallb_auto_assign' configuration variable is deprecated, please use 'metallb_auto_assign' instead" + when: + - matallb_auto_assign is defined + - name: Kubernetes Apps | Check AppArmor status command: which apparmor_parser register: apparmor_status diff --git a/roles/kubernetes-apps/metallb/templates/metallb-config.yml.j2 b/roles/kubernetes-apps/metallb/templates/metallb-config.yml.j2 index 9bd7538716d27c696f0dc9ecf561e4fdd199caaf..35f3d4e7ea7a89244fed033c7f2897391f8a43da 100644 --- a/roles/kubernetes-apps/metallb/templates/metallb-config.yml.j2 +++ b/roles/kubernetes-apps/metallb/templates/metallb-config.yml.j2 @@ -31,7 +31,7 @@ data: {% for ip_range in metallb_ip_range %} - {{ ip_range }} {% endfor %} -{% if matallb_auto_assign == false %} +{% if metallb_auto_assign == false %} auto-assign: false {% endif %} {% if metallb_additional_address_pools is defined %}{% for pool in metallb_additional_address_pools %}