# # {{ ansible_managed }} # {% for network in my_wireguard_networks %} protocol bgp mwu_{{ network.remote }} from ibgp_mwu { interface "wg-{{ network.remote[:11] }}"; source address {{ 'fe80::/64' | ipaddr(magic) | ipaddr('address') }}; neighbor {{ 'fe80::/64' | ipaddr(network.remote_magic) | ipaddr('address') }} as mwu_as; }; {% endfor %} {% if server_type == 'gateway' %} {% for item, value in bgp_legacy_servers.items() %} {% if item != inventory_hostname_short %} protocol bgp mwu_{{ item }}_legacy from ibgp_mwu { source address mwu_address_legacy; neighbor {{ value.ipv6 }} as mwu_as; }; {% endif %} {% endfor %} {% endif %}