mirror of
https://github.com/kubernetes-sigs/kubespray.git
synced 2026-02-01 01:28:11 -03:30
Add serviceExternalIPs option for calico installation (#6928)
This commit is contained in:
@@ -22,6 +22,9 @@ global_as_num: "64512"
|
||||
# defaults. The value should be a number, not a string.
|
||||
# calico_mtu: 1500
|
||||
|
||||
# Advertise Service External IPs
|
||||
calico_advertise_service_external_ips: []
|
||||
|
||||
# Limits for apps
|
||||
calico_node_memory_limit: 500M
|
||||
calico_node_cpu_limit: 300m
|
||||
|
||||
@@ -154,6 +154,12 @@
|
||||
- inventory_hostname == groups['kube-master'][0]
|
||||
- 'calico_conf.stdout == "0"'
|
||||
|
||||
- name: Populate Service External IPs
|
||||
set_fact:
|
||||
_service_external_ips: "{{ _service_external_ips|default([]) + [ {'cidr': item} ] }}"
|
||||
with_items: "{{ calico_advertise_service_external_ips }}"
|
||||
run_once: yes
|
||||
|
||||
- name: "Determine nodeToNodeMesh needed state"
|
||||
set_fact:
|
||||
nodeToNodeMeshEnabled: "false"
|
||||
@@ -174,6 +180,7 @@
|
||||
"spec": {
|
||||
"logSeverityScreen": "Info",
|
||||
"nodeToNodeMeshEnabled": {{ nodeToNodeMeshEnabled|default('true') }} ,
|
||||
"serviceExternalIPs": {{ _service_external_ips|default([]) }},
|
||||
"asNumber": {{ global_as_num }} }}
|
||||
changed_when: false
|
||||
when:
|
||||
|
||||
Reference in New Issue
Block a user