Browse Source

Allow calico ipPool to be created with mode "cross-subnet"

pull/1411/head
Kevin Jing Qiu 7 years ago
parent
commit
a742d10c54
2 changed files with 2 additions and 1 deletions
  1. 1
      roles/network_plugin/calico/defaults/main.yml
  2. 2
      roles/network_plugin/calico/tasks/main.yml

1
roles/network_plugin/calico/defaults/main.yml

@ -4,6 +4,7 @@ nat_outgoing: true
# Use IP-over-IP encapsulation across hosts
ipip: false
ipip_mode: always # change to "cross-subnet" if you only want ipip encapsulation on traffic going across subnets
# Set to true if you want your calico cni binaries to overwrite the
# ones from hyperkube while leaving other cni plugins intact.

2
roles/network_plugin/calico/tasks/main.yml

@ -94,7 +94,7 @@
shell: >
echo '{
"kind": "ipPool",
"spec": {"disabled": false, "ipip": {"enabled": {{ cloud_provider is defined or ipip }}},
"spec": {"disabled": false, "ipip": {"enabled": {{ cloud_provider is defined or ipip }}, "mode": "{{ ipip_mode }}"},
"nat-outgoing": {{ nat_outgoing|default(false) and not peer_with_router|default(false) }}},
"apiVersion": "v1",
"metadata": {"cidr": "{{ kube_pods_subnet }}"}

Loading…
Cancel
Save