Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feat(eos_cli_config_gen): Added support for neighbor x.x.x.x encapsulation mpls next-hop-self source-intf <source-interface> #4608

Merged
merged 8 commits into from
Oct 28, 2024
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ ASN Notation: asplain
| Neighbor | Activate | Encapsulation |
| -------- | -------- | ------------- |
| 192.168.255.3 | True | default |
| 192.168.255.4 | False | default |
| 192.168.255.4 | False | mpls |

##### EVPN Neighbor Default Encapsulation

Expand Down Expand Up @@ -145,5 +145,6 @@ router bgp 65101
neighbor 192.168.255.3 activate
neighbor 192.168.255.4 rcf in Address_Family_EVPN_In()
neighbor 192.168.255.4 rcf out Address_Family_EVPN_Out()
neighbor 192.168.255.4 encapsulation mpls next-hop-self source-interface Ethernet1
layer-2 fec in-place update timeout 100 seconds
```
Original file line number Diff line number Diff line change
Expand Up @@ -34,4 +34,5 @@ router bgp 65101
neighbor 192.168.255.3 activate
neighbor 192.168.255.4 rcf in Address_Family_EVPN_In()
neighbor 192.168.255.4 rcf out Address_Family_EVPN_Out()
neighbor 192.168.255.4 encapsulation mpls next-hop-self source-interface Ethernet1
layer-2 fec in-place update timeout 100 seconds
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,8 @@ router_bgp:
- ip_address: 192.168.255.4
rcf_in: Address_Family_EVPN_In()
rcf_out: Address_Family_EVPN_Out()
encapsulation: mpls
next_hop_self_source_interface: Ethernet1
peer_groups:
- name: EVPN-OVERLAY-PEERS
activate: true
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -924,8 +924,12 @@ router bgp {{ router_bgp.as }}
neighbor {{ neighbor.ip_address }} additional-paths send {{ neighbor.additional_paths.send }}
{% endif %}
{% endif %}
{% if neighbor.encapsulation is arista.avd.defined %}
neighbor {{ neighbor.ip_address }} encapsulation {{ neighbor.encapsulation }}
{% if neighbor.encapsulation is arista.avd.defined %}
{% set encapsulation_cli = "neighbor " ~ neighbor.ip_address ~ " encapsulation " ~ neighbor.encapsulation %}
{% if neighbor.encapsulation == "mpls" and neighbor.next_hop_self_source_interface is arista.avd.defined %}
{% set encapsulation_cli = encapsulation_cli ~ " next-hop-self source-interface " ~ neighbor.next_hop_self_source_interface %}
{% endif %}
{{ encapsulation_cli }}
{% endif %}
{% endfor %}
{% if router_bgp.address_family_evpn.domain_identifier is arista.avd.defined %}
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -1329,6 +1329,9 @@ keys:
- "mpls"
- "path-selection"
description: Transport encapsulation for the neighbor.
next_hop_self_source_interface:
type: str
description: Source interface name for MPLS encapsulation. Requires `encapsulation` to be set as `mpls`.
gmuloc marked this conversation as resolved.
Show resolved Hide resolved
peer_groups:
type: list
primary_key: name
Expand Down
Loading