bird6.conf.j2 709 B

123456789101112131415161718192021222324252627282930
  1. #
  2. # This file is managed by ansible. Do not edit by hand!
  3. #
  4. protocol direct {
  5. interface "bat*";
  6. interface "peer-*";
  7. interface "lo";
  8. }
  9. {% if mesh_ipv6 is defined %}
  10. template bgp ibgp {
  11. local as {{as}};
  12. source address {{mesh_ipv6|ipaddr('address')}};
  13. import all;
  14. export all;
  15. next hop self;
  16. direct;
  17. gateway direct;
  18. }
  19. {% for host in groups['all'] %}
  20. {% if hostvars[host]['inventory_hostname'] != inventory_hostname %}
  21. protocol bgp {{hostvars[host]['inventory_hostname_short']}} from ibgp {
  22. neighbor {{hostvars[host].mesh_ipv6|ipaddr('address')}} as {{as}};
  23. default bgp_med 4;
  24. }
  25. {% endif %}
  26. {% endfor %}
  27. {% endif %}