From 8f9fe3ca424abc56d212a96af4ec5750a29e7673 Mon Sep 17 00:00:00 2001 From: Michal Cmarada Date: Fri, 4 May 2018 16:13:09 +0200 Subject: HC2VPP-253 - Bump routing models This patch updates (for support of SRv6 and MPLS) routing models to: - hc2vpp-ietf-routing@2018-03-13.yang (RFC 8349, https://tools.ietf.org/html/rfc8349) - hc2vpp-ietf-ipv4-unicast-routing@2018-03-13.yang (RFC 8349) - hc2vpp-ietf-ipv6-unicast-routing@2018-03-13.yang (RFC 8349) - hc2vpp-ietf-ipv6-router-advertisements@2018-03-13 (RFC 8349) - hc2vpp-ietf-routing-types@2017-12-04 (RFC 8294 ,https://tools.ietf.org/html/rfc8294) Due to odl bugs these models were changed, see HC2VPP-298 for more details. Significant changes in updated models: - Routing instance was removed, we used vpp-routing-instance as single instance before, which is no longer needed. - Routing-protocol and Routing-protocols were refactored to Control-plane-protocol/s. Control-protocol now uses type and name as key - Route Key was changed from id to ipPrefix - Next-hop and Next-Hop-list were refactored See attached routing_postman_collection.json for updated data structures and examples for both IPv4 and IPv6 routes. For router advertisements see routing_advertisments_postman_collection.json Another fixes in this patch: - fixes in MPLS module due to Routing model updates - fixes doc module due to changes in Routing model Change-Id: I33704a50061aef97dfbd73a7701ff6fe5274d6f0 Signed-off-by: Michal Cmarada --- .../routing_advertisements_postman_collection.json | 409 +++++++++++++++++++++ 1 file changed, 409 insertions(+) create mode 100755 routing/routing_advertisements_postman_collection.json (limited to 'routing/routing_advertisements_postman_collection.json') diff --git a/routing/routing_advertisements_postman_collection.json b/routing/routing_advertisements_postman_collection.json new file mode 100755 index 000000000..84e007677 --- /dev/null +++ b/routing/routing_advertisements_postman_collection.json @@ -0,0 +1,409 @@ +{ + "info": { + "_postman_id": "1e67602e-acf4-4487-8173-410d11672369", + "name": "Routing Advertisments", + "description": "Example requests describing how to configure RA using Honeycomb", + "schema": "https://schema.getpostman.com/json/collection/v2.1.0/collection.json" + }, + "item": [ + { + "name": "Enable GigabitEthernet0/8/0", + "request": { + "method": "PUT", + "header": [ + { + "key": "Authorization", + "value": "Basic YWRtaW46YWRtaW4=" + }, + { + "key": "Content-Type", + "value": "application/json" + } + ], + "body": { + "mode": "raw", + "raw": "{\n \"interface\": [\n {\n \"name\": \"GigabitEthernet0/8/0\",\n \"type\": \"iana-if-type:ethernetCsmacd\",\n \"enabled\": true,\n \"v3po:ethernet\": {\n \"mtu\": 9216\n }\n }\n ]\n}" + }, + "url": { + "raw": "http://localhost:8183/restconf/config/ietf-interfaces:interfaces/interface/GigabitEthernet0%2F8%2F0", + "protocol": "http", + "host": [ + "localhost" + ], + "port": "8183", + "path": [ + "restconf", + "config", + "ietf-interfaces:interfaces", + "interface", + "GigabitEthernet0%2F8%2F0" + ] + }, + "description": "Interface needs to be enabled before configuring RA." + }, + "response": [] + }, + { + "name": "Add ipv6", + "request": { + "method": "PUT", + "header": [ + { + "key": "Authorization", + "value": "Basic YWRtaW46YWRtaW4=" + }, + { + "key": "Content-Type", + "value": "application/json" + } + ], + "body": { + "mode": "raw", + "raw": "{\r\n \r\n \"ipv6\":{\r\n \"address\":{\r\n \"ip\":\"2001:0db8:0a0b:12f0:0000:0000:0000:0001\",\r\n \"prefix-length\":64\r\n }\r\n \r\n }\r\n}" + }, + "url": { + "raw": "http://localhost:8183/restconf/config/ietf-interfaces:interfaces/interface/GigabitEthernet0%2F8%2F0/ipv6", + "protocol": "http", + "host": [ + "localhost" + ], + "port": "8183", + "path": [ + "restconf", + "config", + "ietf-interfaces:interfaces", + "interface", + "GigabitEthernet0%2F8%2F0", + "ipv6" + ] + }, + "description": "IP6 needs to be enabled (e.g. by adding ip6 address) before configuring RA." + }, + "response": [] + }, + { + "name": "Configure RA", + "request": { + "method": "PUT", + "header": [ + { + "key": "Authorization", + "value": "Basic YWRtaW46YWRtaW4=" + }, + { + "key": "Content-Type", + "value": "application/json" + } + ], + "body": { + "mode": "raw", + "raw": "{\n\t\"ipv6-router-advertisements\" : {\n\t\t\"send-advertisements\" : \"true\",\n\t\t\"min-rtr-adv-interval\" : \"20\",\n\t\t\"max-rtr-adv-interval\" : \"100\",\n\t\t\"default-lifetime\" : \"601\",\n\t\t\"vpp-routing-ra:suppress-link-layer\" : \"false\",\n\t\t\"vpp-routing-ra:initial-count\" : \"2\",\n\t\t\"vpp-routing-ra:initial-interval\" : \"15\"\n\t}\n}" + }, + "url": { + "raw": "http://localhost:8183/restconf/config/ietf-interfaces:interfaces/interface/GigabitEthernet0%2F8%2F0/ipv6/ipv6-router-advertisements/", + "protocol": "http", + "host": [ + "localhost" + ], + "port": "8183", + "path": [ + "restconf", + "config", + "ietf-interfaces:interfaces", + "interface", + "GigabitEthernet0%2F8%2F0", + "ipv6", + "ipv6-router-advertisements", + "" + ] + }, + "description": "Equivalent of\n\nvppctl ip6 nd GigabitEthernet0/8/0 ra-interval 100 20 ra-lifetime 6001\n\ncan be verified with\n\nvppctl show ip6 interface GigabitEthernet0/8/0" + }, + "response": [] + }, + { + "name": "Add prefix1", + "request": { + "method": "PUT", + "header": [ + { + "key": "Authorization", + "value": "Basic YWRtaW46YWRtaW4=" + }, + { + "key": "Content-Type", + "value": "application/json" + } + ], + "body": { + "mode": "raw", + "raw": "{\n\t\"prefix\": [\n\t\t{\n\t\t\t\"prefix-spec\" : \"2001:0db8:0a0b:12f0:0000:0000:0000:0002/64\",\n\t\t\t\"autonomous-flag\" : \"true\",\n\t\t\t \"vpp-routing-ra:advertise-router-address\" : \"true\"\n\t\t}\n\t]\n}" + }, + "url": { + "raw": "http://localhost:8183/restconf/config/ietf-interfaces:interfaces/interface/GigabitEthernet0%2F8%2F0/ipv6/ipv6-router-advertisements/prefix-list/prefix/2001:0db8:0a0b:12f0:0000:0000:0000:0002%2F64", + "protocol": "http", + "host": [ + "localhost" + ], + "port": "8183", + "path": [ + "restconf", + "config", + "ietf-interfaces:interfaces", + "interface", + "GigabitEthernet0%2F8%2F0", + "ipv6", + "ipv6-router-advertisements", + "prefix-list", + "prefix", + "2001:0db8:0a0b:12f0:0000:0000:0000:0002%2F64" + ] + }, + "description": "Equivalent of\n\nvppctl ip6 nd GigabitEthernet0/8/0 prefix 2001:db8:a0b:12f0::2/64 infinite\n\ncan be verified with\n\nvppctl show ip6 interface GigabitEthernet0/8/0" + }, + "response": [] + }, + { + "name": "Add prefix2", + "request": { + "method": "PUT", + "header": [ + { + "key": "Authorization", + "value": "Basic YWRtaW46YWRtaW4=" + }, + { + "key": "Content-Type", + "value": "application/json" + } + ], + "body": { + "mode": "raw", + "raw": "{\n\t\"prefix\": [\n\t\t{\n\t\t\t\"prefix-spec\" : \"2002:0db8:0a0b:12f0:0000:0000:0000:0002/64\",\n\t\t\t\"valid-lifetime\" : \"0xffffffff\"\n\t\t}\n\t]\n}" + }, + "url": { + "raw": "http://localhost:8183/restconf/config/ietf-interfaces:interfaces/interface/GigabitEthernet0%2F8%2F0/ipv6/ipv6-router-advertisements/prefix-list/prefix/2002:0db8:0a0b:12f0:0000:0000:0000:0002%2F64", + "protocol": "http", + "host": [ + "localhost" + ], + "port": "8183", + "path": [ + "restconf", + "config", + "ietf-interfaces:interfaces", + "interface", + "GigabitEthernet0%2F8%2F0", + "ipv6", + "ipv6-router-advertisements", + "prefix-list", + "prefix", + "2002:0db8:0a0b:12f0:0000:0000:0000:0002%2F64" + ] + }, + "description": "Equivalent of\n\nvppctl ip6 nd GigabitEthernet0/8/0 prefix 2002:db8:a0b:12f0::2/64 infinite\n\ncan be verified with\n\nvppctl show ip6 interface GigabitEthernet0/8/0" + }, + "response": [] + }, + { + "name": "Delete prefix1", + "request": { + "method": "DELETE", + "header": [ + { + "key": "Authorization", + "value": "Basic YWRtaW46YWRtaW4=" + }, + { + "key": "Content-Type", + "value": "application/json" + } + ], + "body": { + "mode": "raw", + "raw": "" + }, + "url": { + "raw": "http://localhost:8183/restconf/config/ietf-interfaces:interfaces/interface/GigabitEthernet0%2F8%2F0/ipv6/ipv6-router-advertisements/prefix-list/prefix/2001:0db8:0a0b:12f0:0000:0000:0000:0002%2F64", + "protocol": "http", + "host": [ + "localhost" + ], + "port": "8183", + "path": [ + "restconf", + "config", + "ietf-interfaces:interfaces", + "interface", + "GigabitEthernet0%2F8%2F0", + "ipv6", + "ipv6-router-advertisements", + "prefix-list", + "prefix", + "2001:0db8:0a0b:12f0:0000:0000:0000:0002%2F64" + ] + }, + "description": "Equivalent of\n\nvppctl ip6 nd GigabitEthernet0/8/0 no prefix 2001:db8:a0b:12f0::2/64\n\ncan be verified with\n\nvppctl show ip6 interface GigabitEthernet0/8/0" + }, + "response": [] + }, + { + "name": "Delete prefix2", + "request": { + "method": "DELETE", + "header": [ + { + "key": "Authorization", + "value": "Basic YWRtaW46YWRtaW4=" + }, + { + "key": "Content-Type", + "value": "application/json" + } + ], + "body": { + "mode": "raw", + "raw": "" + }, + "url": { + "raw": "http://localhost:8183/restconf/config/ietf-interfaces:interfaces/interface/GigabitEthernet0%2F8%2F0/ipv6/ipv6-router-advertisements/prefix-list/prefix/2002:0db8:0a0b:12f0:0000:0000:0000:0002%2F64", + "protocol": "http", + "host": [ + "localhost" + ], + "port": "8183", + "path": [ + "restconf", + "config", + "ietf-interfaces:interfaces", + "interface", + "GigabitEthernet0%2F8%2F0", + "ipv6", + "ipv6-router-advertisements", + "prefix-list", + "prefix", + "2002:0db8:0a0b:12f0:0000:0000:0000:0002%2F64" + ] + }, + "description": "Equivalent of\n\nvppctl ip6 nd GigabitEthernet0/8/0 no prefix 2002:db8:a0b:12f0::2/64\n\ncan be verified with\n\nvppctl show ip6 interface GigabitEthernet0/8/0" + }, + "response": [] + }, + { + "name": "Disable RA", + "request": { + "method": "DELETE", + "header": [ + { + "key": "Authorization", + "value": "Basic YWRtaW46YWRtaW4=" + }, + { + "key": "Content-Type", + "value": "application/json" + } + ], + "body": { + "mode": "raw", + "raw": "" + }, + "url": { + "raw": "http://localhost:8183/restconf/config/ietf-interfaces:interfaces/interface/GigabitEthernet0%2F8%2F0/ipv6/ipv6-router-advertisements/", + "protocol": "http", + "host": [ + "localhost" + ], + "port": "8183", + "path": [ + "restconf", + "config", + "ietf-interfaces:interfaces", + "interface", + "GigabitEthernet0%2F8%2F0", + "ipv6", + "ipv6-router-advertisements", + "" + ] + }, + "description": "Suppresses sending RA messages for GigabitEthernet0/8/0\n\nEquivalent of\n\nvppctl ip6 nd GigabitEthernet0/8/0 ra-suppress" + }, + "response": [] + }, + { + "name": "Read RA config for GigabitEthernet0/8/0", + "request": { + "method": "GET", + "header": [ + { + "key": "Authorization", + "value": "Basic YWRtaW46YWRtaW4=" + }, + { + "key": "Content-Type", + "value": "application/json" + } + ], + "body": { + "mode": "raw", + "raw": "{\n\t\"interface\": [\n\t\t{\n\t\t\t\"name\" : \"GigabitEthernet0/8/0\",\n\t\t\t\"ipv6-router-advertisements\" : {\n\t\t\t\t\"send-advertisements\" : \"true\",\n\t\t\t\t\"min-rtr-adv-interval\" : \"20\",\n\t\t\t\t\"max-rtr-adv-interval\" : \"100\",\n\t\t\t\t\"default-lifetime\" : \"601\",\n\t\t\t\t\"vpp-routing-ra:suppress-link-layer\" : \"false\",\n\t\t\t\t\"vpp-routing-ra:initial-count\" : \"2\",\n\t\t\t\t\"vpp-routing-ra:initial-interval\" : \"15\"\n\t\t\t}\n\t\t}\n\t]\n}" + }, + "url": { + "raw": "http://localhost:8183/restconf/config/ietf-interfaces:interfaces/interface/GigabitEthernet0%2F8%2F0/ipv6/ipv6-router-advertisements/", + "protocol": "http", + "host": [ + "localhost" + ], + "port": "8183", + "path": [ + "restconf", + "config", + "ietf-interfaces:interfaces", + "interface", + "GigabitEthernet0%2F8%2F0", + "ipv6", + "ipv6-router-advertisements", + "" + ] + } + }, + "response": [] + }, + { + "name": "Read GigabitEthernet0/8/0", + "request": { + "method": "GET", + "header": [ + { + "key": "Authorization", + "value": "Basic YWRtaW46YWRtaW4=" + }, + { + "key": "Content-Type", + "value": "application/json" + } + ], + "body": { + "mode": "raw", + "raw": "{\n\t\"interface\": [\n\t\t{\n\t\t\t\"name\" : \"GigabitEthernet0/8/0\",\n\t\t\t\"ipv6-router-advertisements\" : {\n\t\t\t\t\"send-advertisements\" : \"true\",\n\t\t\t\t\"min-rtr-adv-interval\" : \"20\",\n\t\t\t\t\"max-rtr-adv-interval\" : \"100\",\n\t\t\t\t\"default-lifetime\" : \"601\",\n\t\t\t\t\"vpp-routing-ra:suppress-link-layer\" : \"false\",\n\t\t\t\t\"vpp-routing-ra:initial-count\" : \"2\",\n\t\t\t\t\"vpp-routing-ra:initial-interval\" : \"15\"\n\t\t\t}\n\t\t}\n\t]\n}" + }, + "url": { + "raw": "http://localhost:8183/restconf/config/ietf-interfaces:interfaces/interface/GigabitEthernet0%2F8%2F0/", + "protocol": "http", + "host": [ + "localhost" + ], + "port": "8183", + "path": [ + "restconf", + "config", + "ietf-interfaces:interfaces", + "interface", + "GigabitEthernet0%2F8%2F0", + "" + ] + } + }, + "response": [] + } + ] +} \ No newline at end of file -- cgit 1.2.3-korg