|
|
@ -54,7 +54,7 @@ interfaces {
|
|
|
|
}
|
|
|
|
}
|
|
|
|
{% endif %}
|
|
|
|
{% endif %}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
{% elif iface_data.get('form_factor',{}).get('label','') != 'Virtual' %}
|
|
|
|
{% elif iface_data.get('type',{}).get('label','') != 'Virtual' %}
|
|
|
|
ethernet {{ iface_name }} {
|
|
|
|
ethernet {{ iface_name }} {
|
|
|
|
description "{{ iface_data['description'].replace('"','\\"') or "-" }}{% if iface_data['connected_endpoint'] and iface_data['connected_endpoint']['connection_status']['value'] %} ({% if iface_data['connected_endpoint']['device'] %}{{ iface_data['connected_endpoint']['name'] }} @ {{ iface_data['connected_endpoint']['device']['display_name'] }}{% endif %}){% endif %}"
|
|
|
|
description "{{ iface_data['description'].replace('"','\\"') or "-" }}{% if iface_data['connected_endpoint'] and iface_data['connected_endpoint']['connection_status']['value'] %} ({% if iface_data['connected_endpoint']['device'] %}{{ iface_data['connected_endpoint']['name'] }} @ {{ iface_data['connected_endpoint']['device']['display_name'] }}{% endif %}){% endif %}"
|
|
|
|
{% for address in iface_data['addresses'] %}
|
|
|
|
{% for address in iface_data['addresses'] %}
|
|
|
@ -233,7 +233,6 @@ protocols {
|
|
|
|
address-family {
|
|
|
|
address-family {
|
|
|
|
{% if as_data['address-family'].get('ipv4-unicast',None) %}
|
|
|
|
{% if as_data['address-family'].get('ipv4-unicast',None) %}
|
|
|
|
ipv4-unicast {
|
|
|
|
ipv4-unicast {
|
|
|
|
{% if as_data['address-family']['ipv4-unicast'].get('route-reflector-client',False) %}route-reflector-client{% endif %}
|
|
|
|
|
|
|
|
redistribute {
|
|
|
|
redistribute {
|
|
|
|
{% for redistribute, redist_data in as_data['address-family']['ipv4-unicast'].get('redistribute',{}).items() %}
|
|
|
|
{% for redistribute, redist_data in as_data['address-family']['ipv4-unicast'].get('redistribute',{}).items() %}
|
|
|
|
{{ redistribute }} {
|
|
|
|
{{ redistribute }} {
|
|
|
@ -250,7 +249,6 @@ protocols {
|
|
|
|
{% endif %}
|
|
|
|
{% endif %}
|
|
|
|
{% if as_data['address-family'].get('ipv6-unicast',None) %}
|
|
|
|
{% if as_data['address-family'].get('ipv6-unicast',None) %}
|
|
|
|
ipv6-unicast {
|
|
|
|
ipv6-unicast {
|
|
|
|
{% if as_data['address-family']['ipv6-unicast'].get('route-reflector-client',False) %}route-reflector-client{% endif %}
|
|
|
|
|
|
|
|
redistribute {
|
|
|
|
redistribute {
|
|
|
|
{% for redistribute, redist_data in as_data['address-family']['ipv6-unicast'].get('redistribute',{}).items() %}
|
|
|
|
{% for redistribute, redist_data in as_data['address-family']['ipv6-unicast'].get('redistribute',{}).items() %}
|
|
|
|
{{ redistribute }} {
|
|
|
|
{{ redistribute }} {
|
|
|
@ -279,6 +277,8 @@ protocols {
|
|
|
|
address-family {
|
|
|
|
address-family {
|
|
|
|
{% if 'ipv4-unicast' in neighbor_data['address-family'] %}
|
|
|
|
{% if 'ipv4-unicast' in neighbor_data['address-family'] %}
|
|
|
|
ipv4-unicast {
|
|
|
|
ipv4-unicast {
|
|
|
|
|
|
|
|
{% if neighbor_data['address-family']['ipv4-unicast'].get('route-reflector-client',False) %}route-reflector-client{% endif %}
|
|
|
|
|
|
|
|
{% if neighbor_data['address-family']['ipv4-unicast'].get('route-server-client',False) %}route-server-client{% endif %}
|
|
|
|
{% if 'prefix-list' in neighbor_data['address-family']['ipv4-unicast'] %}
|
|
|
|
{% if 'prefix-list' in neighbor_data['address-family']['ipv4-unicast'] %}
|
|
|
|
prefix-list {
|
|
|
|
prefix-list {
|
|
|
|
{% if 'export' in neighbor_data['address-family']['ipv4-unicast']['prefix-list'] %}export {{ neighbor_data['address-family']['ipv4-unicast']['prefix-list']['export'] }}{% endif %}
|
|
|
|
{% if 'export' in neighbor_data['address-family']['ipv4-unicast']['prefix-list'] %}export {{ neighbor_data['address-family']['ipv4-unicast']['prefix-list']['export'] }}{% endif %}
|
|
|
@ -313,6 +313,8 @@ protocols {
|
|
|
|
{% endif %}
|
|
|
|
{% endif %}
|
|
|
|
{% if 'ipv6-unicast' in neighbor_data['address-family'] %}
|
|
|
|
{% if 'ipv6-unicast' in neighbor_data['address-family'] %}
|
|
|
|
ipv6-unicast {
|
|
|
|
ipv6-unicast {
|
|
|
|
|
|
|
|
{% if neighbor_data['address-family']['ipv6-unicast'].get('route-reflector-client',False) %}route-reflector-client{% endif %}
|
|
|
|
|
|
|
|
{% if neighbor_data['address-family']['ipv6-unicast'].get('route-server-client',False) %}route-server-client{% endif %}
|
|
|
|
{% if 'prefix-list' in neighbor_data['address-family']['ipv6-unicast'] %}
|
|
|
|
{% if 'prefix-list' in neighbor_data['address-family']['ipv6-unicast'] %}
|
|
|
|
prefix-list {
|
|
|
|
prefix-list {
|
|
|
|
{% if 'export' in neighbor_data['address-family']['ipv6-unicast']['prefix-list'] %}export {{ neighbor_data['address-family']['ipv6-unicast']['prefix-list']['export'] }}{% endif %}
|
|
|
|
{% if 'export' in neighbor_data['address-family']['ipv6-unicast']['prefix-list'] %}export {{ neighbor_data['address-family']['ipv6-unicast']['prefix-list']['export'] }}{% endif %}
|
|
|
|