Skip to content

Commit

Permalink
Set next hop to something valid for vxlan routes
Browse files Browse the repository at this point in the history
  • Loading branch information
malanovo committed Dec 29, 2020
1 parent 5a2adcb commit fb052b5
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions napalm/eos/eos.py
Original file line number Diff line number Diff line change
Expand Up @@ -1330,6 +1330,9 @@ def get_route_to(self, destination="", protocol="", longer=False):
if protocol == "bgp" or route_protocol.lower() in ("ebgp", "ibgp"):
nexthop_interface_map = {}
for next_hop in route_details.get("vias"):
if "vtepAddr" in next_hop:
next_hop["nexthopAddr"] = next_hop["vtepAddr"]
next_hop["interface"] = "vxlan1"
nexthop_ip = napalm.base.helpers.ip(next_hop.get("nexthopAddr"))
nexthop_interface_map[nexthop_ip] = next_hop.get("interface")
metric = route_details.get("metric")
Expand Down

0 comments on commit fb052b5

Please sign in to comment.