Skip to content

Commit

Permalink
Add variable to set direct routing on flannel VXLAN (kubernetes-sigs#…
Browse files Browse the repository at this point in the history
  • Loading branch information
willtrnr authored and HoKim98 committed Mar 8, 2023
1 parent acec2e3 commit d03bae0
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -16,3 +16,4 @@
# flannel_backend_type: "vxlan"
# flannel_vxlan_vni: 1
# flannel_vxlan_port: 8472
# flannel_vxlan_direct_routing: false
1 change: 1 addition & 0 deletions roles/network_plugin/flannel/defaults/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@
flannel_backend_type: "vxlan"
flannel_vxlan_vni: 1
flannel_vxlan_port: 8472
flannel_vxlan_direct_routing: false

# Limits for apps
flannel_memory_limit: 500M
Expand Down
3 changes: 2 additions & 1 deletion roles/network_plugin/flannel/templates/cni-flannel.yml.j2
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,8 @@ data:
"Backend": {
"Type": "{{ flannel_backend_type }}"{% if flannel_backend_type == "vxlan" %},
"VNI": {{ flannel_vxlan_vni }},
"Port": {{ flannel_vxlan_port }}
"Port": {{ flannel_vxlan_port }},
"DirectRouting": {{ flannel_vxlan_direct_routing | to_json }}
{% endif %}
}
}
Expand Down

0 comments on commit d03bae0

Please sign in to comment.