diff options
author | Christian Breunig <christian@breunig.cc> | 2025-06-01 13:36:57 +0200 |
---|---|---|
committer | Christian Breunig <christian@breunig.cc> | 2025-06-01 13:36:57 +0200 |
commit | e5183e60552773ba5b7dd4abc73b9d5967a08b18 (patch) | |
tree | f90c74bf125c20526c3697548495bf9620fbef53 | |
parent | d7df1aea35dedb6fd4542064dbb1219ec6efbdd6 (diff) | |
download | vyos-1x-e5183e60552773ba5b7dd4abc73b9d5967a08b18.tar.gz vyos-1x-e5183e60552773ba5b7dd4abc73b9d5967a08b18.zip |
op-mode: T7509: add "detail" and "wide" modifier for received-routes
show ip bgp neighbors <ip> received-routes [detail [wide]|wide]
show bgp neighbors <ip> received-routes [detail [wide]|wide]
show bgp ipv4 neighbors <ip> received-routes [detail [wide]|wide]
show bgp ipv6 neighbors <ip> received-routes [detail [wide]|wide]
show bgp vrf <name> neighbors <ip> received-routes [detail [wide]|wide]
show bgp vrf <name> ipv4 neighbors <ip> received-routes [detail [wide]|wide]
show bgp vrf <name> ipv6 neighbors <ip> received-routes [detail [wide]|wide]
3 files changed, 14 insertions, 12 deletions
diff --git a/op-mode-definitions/include/bgp/afi-ipv4-ipv6-common.xml.i b/op-mode-definitions/include/bgp/afi-ipv4-ipv6-common.xml.i index a6faa4949..9a743f828 100644 --- a/op-mode-definitions/include/bgp/afi-ipv4-ipv6-common.xml.i +++ b/op-mode-definitions/include/bgp/afi-ipv4-ipv6-common.xml.i @@ -196,12 +196,7 @@ </properties> <command>${vyos_op_scripts_dir}/vtysh_wrapper.sh $@</command> </leafNode> - <leafNode name="received-routes"> - <properties> - <help>Show received routes from BGP neighbor</help> - </properties> - <command>${vyos_op_scripts_dir}/vtysh_wrapper.sh $@</command> - </leafNode> + #include <include/bgp/received-routes.xml.i> <leafNode name="routes"> <properties> <help>Show routes learned from BGP neighbor</help> diff --git a/op-mode-definitions/include/bgp/received-routes.xml.i b/op-mode-definitions/include/bgp/received-routes.xml.i new file mode 100644 index 000000000..55bed7c77 --- /dev/null +++ b/op-mode-definitions/include/bgp/received-routes.xml.i @@ -0,0 +1,12 @@ +<!-- included start from bgp/received-routes.xml.i --> +<node name="received-routes"> + <properties> + <help>Show received routes from a BGP neighbor</help> + </properties> + <command>${vyos_op_scripts_dir}/vtysh_wrapper.sh $@</command> + <children> + #include <include/vtysh-generic-detail-wide.xml.i> + #include <include/vtysh-generic-wide.xml.i> + </children> +</node> +<!-- included end --> diff --git a/op-mode-definitions/include/bgp/show-ip-bgp-common.xml.i b/op-mode-definitions/include/bgp/show-ip-bgp-common.xml.i index 49e035b5f..559b20755 100644 --- a/op-mode-definitions/include/bgp/show-ip-bgp-common.xml.i +++ b/op-mode-definitions/include/bgp/show-ip-bgp-common.xml.i @@ -94,12 +94,7 @@ </properties> <command>${vyos_op_scripts_dir}/vtysh_wrapper.sh $@</command> </leafNode> - <leafNode name="received-routes"> - <properties> - <help>Show the received routes from neighbor</help> - </properties> - <command>${vyos_op_scripts_dir}/vtysh_wrapper.sh $@</command> - </leafNode> + #include <include/bgp/received-routes.xml.i> <leafNode name="routes"> <properties> <help>Show routes learned from neighbor</help> |