summaryrefslogtreecommitdiff
path: root/interface-definitions/include
diff options
context:
space:
mode:
authorChristian Poessinger <christian@poessinger.com>2021-03-10 20:33:36 +0100
committerChristian Poessinger <christian@poessinger.com>2021-03-10 20:33:36 +0100
commitc14098b7b1517d77bf53318cc7964295d54db119 (patch)
treef8c5ec0ee68d8f1c44b5b31577c3553b02875aec /interface-definitions/include
parent607339f6593514a4b4b37b95fd97e5e2d2039585 (diff)
downloadvyos-1x-c14098b7b1517d77bf53318cc7964295d54db119.tar.gz
vyos-1x-c14098b7b1517d77bf53318cc7964295d54db119.zip
bgp: evpn: T1513: add support for per VNI route-distinguished and route-target
set protocols bgp 65010 address-family l2vpn-evpn vni 100 route-target both 516:10516 set protocols bgp 65010 address-family l2vpn-evpn vni 100 rd 192.168.0.1:514 Todo: add verify() step to check if at least one evpn enabled BGP neighbor exits, else FRR will error out with: This command is only supported under EVPN VRF
Diffstat (limited to 'interface-definitions/include')
-rw-r--r--interface-definitions/include/bgp-afi-l2vpn-common.xml.i13
-rw-r--r--interface-definitions/include/bgp-route-target.xml.i45
2 files changed, 58 insertions, 0 deletions
diff --git a/interface-definitions/include/bgp-afi-l2vpn-common.xml.i b/interface-definitions/include/bgp-afi-l2vpn-common.xml.i
index 11b1cf6bf..2bbf57532 100644
--- a/interface-definitions/include/bgp-afi-l2vpn-common.xml.i
+++ b/interface-definitions/include/bgp-afi-l2vpn-common.xml.i
@@ -11,4 +11,17 @@
<valueless/>
</properties>
</leafNode>
+<leafNode name="rd">
+ <properties>
+ <help>Route Distinguisher</help>
+ <valueHelp>
+ <format>txt</format>
+ <description>Route Distinguisher, (x.x.x.x:yyy|xxxx:yyyy)</description>
+ </valueHelp>
+ <constraint>
+ <regex>^((25[0-5]|2[0-4][0-9]|[1][0-9][0-9]|[1-9][0-9]|[0-9]?)(\.(25[0-5]|2[0-4][0-9]|[1][0-9][0-9]|[1-9][0-9]|[0-9]?)){3}|[0-9]{1,10}):[0-9]{1,5}$</regex>
+ </constraint>
+ </properties>
+</leafNode>
+#include <include/bgp-route-target.xml.i>
<!-- included end -->
diff --git a/interface-definitions/include/bgp-route-target.xml.i b/interface-definitions/include/bgp-route-target.xml.i
new file mode 100644
index 000000000..c3df56a74
--- /dev/null
+++ b/interface-definitions/include/bgp-route-target.xml.i
@@ -0,0 +1,45 @@
+<!-- included start from bgp-route-target.xml.i -->
+<node name="route-target">
+ <properties>
+ <help>Route Target</help>
+ </properties>
+ <children>
+ <leafNode name="both">
+ <properties>
+ <help>Route Target both import and export</help>
+ <valueHelp>
+ <format>txt</format>
+ <description>Route target (x.x.x.x:yyy|xxxx:yyyy)</description>
+ </valueHelp>
+ <constraint>
+ <regex>^((25[0-5]|2[0-4][0-9]|[1][0-9][0-9]|[1-9][0-9]|[0-9]?)(\.(25[0-5]|2[0-4][0-9]|[1][0-9][0-9]|[1-9][0-9]|[0-9]?)){3}|[0-9]{1,10}):[0-9]{1,5}$</regex>
+ </constraint>
+ </properties>
+ </leafNode>
+ <leafNode name="export">
+ <properties>
+ <help>Route Target export</help>
+ <valueHelp>
+ <format>txt</format>
+ <description>Route target (x.x.x.x:yyy|xxxx:yyyy)</description>
+ </valueHelp>
+ <constraint>
+ <regex>^((25[0-5]|2[0-4][0-9]|[1][0-9][0-9]|[1-9][0-9]|[0-9]?)(\.(25[0-5]|2[0-4][0-9]|[1][0-9][0-9]|[1-9][0-9]|[0-9]?)){3}|[0-9]{1,10}):[0-9]{1,5}$</regex>
+ </constraint>
+ </properties>
+ </leafNode>
+ <leafNode name="import">
+ <properties>
+ <help>Route Target import</help>
+ <valueHelp>
+ <format>txt</format>
+ <description>Route target (x.x.x.x:yyy|xxxx:yyyy)</description>
+ </valueHelp>
+ <constraint>
+ <regex>^((25[0-5]|2[0-4][0-9]|[1][0-9][0-9]|[1-9][0-9]|[0-9]?)(\.(25[0-5]|2[0-4][0-9]|[1][0-9][0-9]|[1-9][0-9]|[0-9]?)){3}|[0-9]{1,10}):[0-9]{1,5}$</regex>
+ </constraint>
+ </properties>
+ </leafNode>
+ </children>
+</node>
+<!-- included end -->