diff --git a/cloudbuild/virtual.sh b/cloudbuild/virtual.sh index 25399c7ec57..88a2805d39d 100755 --- a/cloudbuild/virtual.sh +++ b/cloudbuild/virtual.sh @@ -82,6 +82,7 @@ function metadata_kne_topology() { kne_topology_file["TESTBED_DUT_ATE_2LINKS"]="${topo_prefix}/dutate.textproto" kne_topology_file["TESTBED_DUT_ATE_4LINKS"]="${topo_prefix}/dutate.textproto" kne_topology_file["TESTBED_DUT_ATE_9LINKS_LAG"]="${topo_prefix}/dutate_lag.textproto" + kne_topology_file["TESTBED_DUT_DUT_ATE_2LINKS"]="${topo_prefix}/dutdutate.textproto" for p in "${!kne_topology_file[@]}"; do if grep -q "testbed.*${p}$" "${metadata_test_path}"/metadata.textproto; then echo "${kne_topology_file[${p}]}" diff --git a/internal/fptest/runtests.go b/internal/fptest/runtests.go index fcc0d3a395a..d6aa487f6c8 100644 --- a/internal/fptest/runtests.go +++ b/internal/fptest/runtests.go @@ -73,6 +73,7 @@ func testbedPathFromMetadata() (string, error) { mpb.Metadata_TESTBED_DUT_ATE_2LINKS: "atedut_2.testbed", mpb.Metadata_TESTBED_DUT_ATE_4LINKS: "atedut_4.testbed", mpb.Metadata_TESTBED_DUT_ATE_9LINKS_LAG: "atedut_9_lag.testbed", + mpb.Metadata_TESTBED_DUT_DUT_ATE_2LINKS: "dutdutate.testbed", } testbedFile, ok := testbedToFile[testbed] if !ok { diff --git a/proto/metadata.proto b/proto/metadata.proto index fbbf5b0b4a0..66920f7d097 100644 --- a/proto/metadata.proto +++ b/proto/metadata.proto @@ -35,6 +35,7 @@ message Metadata { TESTBED_DUT_ATE_2LINKS = 3; TESTBED_DUT_ATE_4LINKS = 4; TESTBED_DUT_ATE_9LINKS_LAG = 5; + TESTBED_DUT_DUT_ATE_2LINKS = 6; } // Testbed on which the test is intended to run. Testbed testbed = 4; diff --git a/proto/metadata_go_proto/metadata.pb.go b/proto/metadata_go_proto/metadata.pb.go index 6169fecfd73..e0f9386124e 100644 --- a/proto/metadata_go_proto/metadata.pb.go +++ b/proto/metadata_go_proto/metadata.pb.go @@ -46,6 +46,7 @@ const ( Metadata_TESTBED_DUT_ATE_2LINKS Metadata_Testbed = 3 Metadata_TESTBED_DUT_ATE_4LINKS Metadata_Testbed = 4 Metadata_TESTBED_DUT_ATE_9LINKS_LAG Metadata_Testbed = 5 + Metadata_TESTBED_DUT_DUT_ATE_2LINKS Metadata_Testbed = 6 ) // Enum value maps for Metadata_Testbed. @@ -57,6 +58,7 @@ var ( 3: "TESTBED_DUT_ATE_2LINKS", 4: "TESTBED_DUT_ATE_4LINKS", 5: "TESTBED_DUT_ATE_9LINKS_LAG", + 6: "TESTBED_DUT_DUT_ATE_2LINKS", } Metadata_Testbed_value = map[string]int32{ "TESTBED_UNSPECIFIED": 0, @@ -65,6 +67,7 @@ var ( "TESTBED_DUT_ATE_2LINKS": 3, "TESTBED_DUT_ATE_4LINKS": 4, "TESTBED_DUT_ATE_9LINKS_LAG": 5, + "TESTBED_DUT_DUT_ATE_2LINKS": 6, } ) @@ -1369,7 +1372,7 @@ var file_metadata_proto_rawDesc = []byte{ 0x74, 0x69, 0x6e, 0x67, 0x1a, 0x31, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x6f, 0x70, 0x65, 0x6e, 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x2f, 0x6f, 0x6e, 0x64, 0x61, 0x74, 0x72, 0x61, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x74, 0x65, 0x73, 0x74, 0x62, 0x65, - 0x64, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x99, 0x3d, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, + 0x64, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0xb9, 0x3d, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x75, 0x75, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x75, 0x75, 0x69, 0x64, 0x12, 0x17, 0x0a, 0x07, 0x70, 0x6c, 0x61, 0x6e, 0x5f, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x70, 0x6c, 0x61, 0x6e, 0x49, @@ -1841,7 +1844,7 @@ var file_metadata_proto_rawDesc = []byte{ 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x27, 0x2e, 0x6f, 0x70, 0x65, 0x6e, 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x2e, 0x74, 0x65, 0x73, 0x74, 0x69, 0x6e, 0x67, 0x2e, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x2e, 0x44, 0x65, 0x76, 0x69, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x52, 0x0a, - 0x64, 0x65, 0x76, 0x69, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x22, 0xa7, 0x01, 0x0a, 0x07, 0x54, + 0x64, 0x65, 0x76, 0x69, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x22, 0xc7, 0x01, 0x0a, 0x07, 0x54, 0x65, 0x73, 0x74, 0x62, 0x65, 0x64, 0x12, 0x17, 0x0a, 0x13, 0x54, 0x45, 0x53, 0x54, 0x42, 0x45, 0x44, 0x5f, 0x55, 0x4e, 0x53, 0x50, 0x45, 0x43, 0x49, 0x46, 0x49, 0x45, 0x44, 0x10, 0x00, 0x12, 0x0f, 0x0a, 0x0b, 0x54, 0x45, 0x53, 0x54, 0x42, 0x45, 0x44, 0x5f, 0x44, 0x55, 0x54, 0x10, 0x01, @@ -1852,7 +1855,9 @@ var file_metadata_proto_rawDesc = []byte{ 0x42, 0x45, 0x44, 0x5f, 0x44, 0x55, 0x54, 0x5f, 0x41, 0x54, 0x45, 0x5f, 0x34, 0x4c, 0x49, 0x4e, 0x4b, 0x53, 0x10, 0x04, 0x12, 0x1e, 0x0a, 0x1a, 0x54, 0x45, 0x53, 0x54, 0x42, 0x45, 0x44, 0x5f, 0x44, 0x55, 0x54, 0x5f, 0x41, 0x54, 0x45, 0x5f, 0x39, 0x4c, 0x49, 0x4e, 0x4b, 0x53, 0x5f, 0x4c, - 0x41, 0x47, 0x10, 0x05, 0x22, 0x6d, 0x0a, 0x04, 0x54, 0x61, 0x67, 0x73, 0x12, 0x14, 0x0a, 0x10, + 0x41, 0x47, 0x10, 0x05, 0x12, 0x1e, 0x0a, 0x1a, 0x54, 0x45, 0x53, 0x54, 0x42, 0x45, 0x44, 0x5f, + 0x44, 0x55, 0x54, 0x5f, 0x44, 0x55, 0x54, 0x5f, 0x41, 0x54, 0x45, 0x5f, 0x32, 0x4c, 0x49, 0x4e, + 0x4b, 0x53, 0x10, 0x06, 0x22, 0x6d, 0x0a, 0x04, 0x54, 0x61, 0x67, 0x73, 0x12, 0x14, 0x0a, 0x10, 0x54, 0x41, 0x47, 0x53, 0x5f, 0x55, 0x4e, 0x53, 0x50, 0x45, 0x43, 0x49, 0x46, 0x49, 0x45, 0x44, 0x10, 0x00, 0x12, 0x14, 0x0a, 0x10, 0x54, 0x41, 0x47, 0x53, 0x5f, 0x41, 0x47, 0x47, 0x52, 0x45, 0x47, 0x41, 0x54, 0x49, 0x4f, 0x4e, 0x10, 0x01, 0x12, 0x18, 0x0a, 0x14, 0x54, 0x41, 0x47, 0x53, diff --git a/topologies/dutdutate.testbed b/topologies/dutdutate.testbed new file mode 100644 index 00000000000..f440a5180fe --- /dev/null +++ b/topologies/dutdutate.testbed @@ -0,0 +1,39 @@ +# proto-file: github.com/openconfig/ondatra/blob/main/proto/testbed.proto +# proto-message: ondatra.Testbed + +# This testbed provides 2 DUTs and ATE connected serially. +# This is used for control plane testing, not traffic testing. + +duts { + id: "dut1" + ports { + id: "port1" + } + ports { + id: "port2" + } +} + +duts { + id: "dut2" + ports { + id: "port1" + } +} + +ates { + id: "ate" + ports { + id: "port1" + } +} + +links { + a: "dut1:port1" + b: "ate:port1" +} + +links { + a: "dut1:port2" + b: "dut2:port1" +} diff --git a/topologies/kne/arista/ceos/dutdutate.textproto b/topologies/kne/arista/ceos/dutdutate.textproto new file mode 100644 index 00000000000..ca353a0a6b9 --- /dev/null +++ b/topologies/kne/arista/ceos/dutdutate.textproto @@ -0,0 +1,56 @@ +name: "arista-ceos-dutdut" +nodes: { + name: "dut1" + vendor: ARISTA + model: "ceos" + os: "eos" + config: { + image: "ceos:latest" + file: "config.cfg" + config_path: "/mnt/flash" + config_file: "startup-config" + cert: { + self_signed: { + cert_name: "gnmiCert.pem" + key_name: "gnmiCertKey.pem" + key_size: 4096 + } + } + } +} +nodes: { + name: "dut2" + vendor: ARISTA + model: "ceos" + os: "eos" + config: { + image: "ceos:latest" + file: "config.cfg" + config_path: "/mnt/flash" + config_file: "startup-config" + cert: { + self_signed: { + cert_name: "gnmiCert.pem" + key_name: "gnmiCertKey.pem" + key_size: 4096 + } + } + } +} +nodes: { + name: "otg" + vendor: KEYSIGHT + version: "0.0.1-9999" # Please update this with the local version from ixiatg-configmap.yaml +} +links: { + a_node: "otg" + a_int: "eth1" + z_node: "dut1" + z_int: "eth1" +} +links: { + a_node: "dut1" + a_int: "eth2" + z_node: "dut2" + z_int: "eth1" +} diff --git a/topologies/kne/cisco/8000e/dutdutate.textproto b/topologies/kne/cisco/8000e/dutdutate.textproto new file mode 100644 index 00000000000..35b040c836f --- /dev/null +++ b/topologies/kne/cisco/8000e/dutdutate.textproto @@ -0,0 +1,56 @@ +name: "cisco-8000e-dutdut" +nodes: { + name: "dut1" + vendor: CISCO + model: "8201" + os: "ios-xr" + config: { + image: "8000e:latest" + file: "config.cfg" + } + interfaces: { + key: "eth1" + value: { + name: "FourHundredGigE0/0/0/0" + } + } + interfaces: { + key: "eth2" + value: { + name: "FourHundredGigE0/0/0/1" + } + } +} +nodes: { + name: "dut2" + vendor: CISCO + model: "8201" + os: "ios-xr" + config: { + image: "8000e:latest" + file: "config.cfg" + } + interfaces: { + key: "eth1" + value: { + name: "FourHundredGigE0/0/0/0" + } + } +} +nodes: { + name: "otg" + vendor: KEYSIGHT + version: "0.0.1-9999" # Please update this with the local version from ixiatg-configmap.yaml +} +links: { + a_node: "otg" + a_int: "eth1" + z_node: "dut1" + z_int: "eth1" +} +links: { + a_node: "dut1" + a_int: "eth2" + z_node: "dut2" + z_int: "eth1" +} diff --git a/topologies/kne/cisco/xrd/dutdutate.textproto b/topologies/kne/cisco/xrd/dutdutate.textproto new file mode 100644 index 00000000000..b1a3593bfc8 --- /dev/null +++ b/topologies/kne/cisco/xrd/dutdutate.textproto @@ -0,0 +1,56 @@ +name: "cisco-xrd-dutdut" +nodes: { + name: "dut1" + vendor: CISCO + model: "xrd" + os: "ios-xr" + config: { + image: "xrd:latest" + file: "config.cfg" + } + interfaces: { + key: "eth1" + value: { + name: "GigabitEthernet0/0/0/0" + } + } + interfaces: { + key: "eth2" + value: { + name: "GigabitEthernet0/0/0/1" + } + } +} +nodes: { + name: "dut2" + vendor: CISCO + model: "xrd" + os: "ios-xr" + config: { + image: "xrd:latest" + file: "config.cfg" + } + interfaces: { + key: "eth1" + value: { + name: "GigabitEthernet0/0/0/0" + } + } +} +nodes: { + name: "otg" + vendor: KEYSIGHT + version: "0.0.1-9999" # Please update this with the local version from ixiatg-configmap.yaml +} +links: { + a_node: "otg" + a_int: "eth1" + z_node: "dut" + z_int: "eth1" +} +links: { + a_node: "dut1" + a_int: "eth2" + z_node: "dut2" + z_int: "eth1" +} diff --git a/topologies/kne/juniper/cptx/dutdutate.textproto b/topologies/kne/juniper/cptx/dutdutate.textproto new file mode 100644 index 00000000000..a1a97e39204 --- /dev/null +++ b/topologies/kne/juniper/cptx/dutdutate.textproto @@ -0,0 +1,75 @@ +name: "juniper-cptx-dutdutate" +nodes: { + name: "dut1" + vendor: JUNIPER + model: "cptx" + os: "evo" + config: { + image: "cptx:latest" + config_path: "/home/evo/configdisk" + config_file: "juniper.conf" + file: "config.cfg" + cert: { + self_signed: { + cert_name: "grpc-server-cert" + key_name: "N/A" + key_size: 4096 + } + } + } + interfaces: { + key: "eth4" + value: { + name: "et-0/0/0:0" + } + } + interfaces: { + key: "eth12" + value: { + name: "et-0/0/1:0" + } + } +} +nodes: { + name: "dut2" + vendor: JUNIPER + model: "cptx" + os: "evo" + config: { + image: "cptx:latest" + config_path: "/home/evo/configdisk" + config_file: "juniper.conf" + file: "config.cfg" + cert: { + self_signed: { + cert_name: "grpc-server-cert" + key_name: "N/A" + key_size: 4096 + } + } + } + interfaces: { + key: "eth12" + value: { + name: "et-0/0/1:0" + } + } +} +nodes: { + name: "otg" + vendor: KEYSIGHT + version: "0.0.1-9999" # Please update this with the local version from ixiatg-configmap.yaml +} +links: { + a_node: "otg" + a_int: "eth1" + z_node: "dut1" + z_int: "eth4" +} +links: { + a_node: "dut1" + a_int: "eth12" + z_node: "dut2" + z_int: "eth12" +} + diff --git a/topologies/kne/nokia/srlinux/dutdutate.textproto b/topologies/kne/nokia/srlinux/dutdutate.textproto new file mode 100644 index 00000000000..4e9a6b4cba5 --- /dev/null +++ b/topologies/kne/nokia/srlinux/dutdutate.textproto @@ -0,0 +1,68 @@ +name: "nokia-srlinux-dutdut" +nodes: { + name: "dut1" + vendor: NOKIA + model: "ixr10" + config: { + image: "srlinux:latest" + file: "config.cfg" + cert: { + self_signed: { + cert_name: "kne-profile" + key_name: "N/A" + key_size: 4096 + } + } + } + interfaces: { + key: "e1-1" + value: { + name: "ethernet-1/1" + } + } + interfaces: { + key: "e1-2" + value: { + name: "ethernet-1/2" + } + } +} +nodes: { + name: "dut2" + vendor: NOKIA + model: "ixr10" + config: { + image: "srlinux:latest" + file: "config.cfg" + cert: { + self_signed: { + cert_name: "kne-profile" + key_name: "N/A" + key_size: 4096 + } + } + } + interfaces: { + key: "e1-1" + value: { + name: "ethernet-1/1" + } + } +} +nodes: { + name: "otg" + vendor: KEYSIGHT + version: "0.0.1-9999" # Please update this with the local version from ixiatg-configmap.yaml +} +links: { + a_node: "otg" + a_int: "eth1" + z_node: "dut1" + z_int: "e1-1" +} +links: { + a_node: "dut1" + a_int: "e1-2" + z_node: "dut2" + z_int: "e1-1" +} diff --git a/topologies/kne/openconfig/lemming/dutdutate.textproto b/topologies/kne/openconfig/lemming/dutdutate.textproto new file mode 100644 index 00000000000..c0b8c9423c5 --- /dev/null +++ b/topologies/kne/openconfig/lemming/dutdutate.textproto @@ -0,0 +1,28 @@ +name: "openconfig-lemming-dutdut" +nodes: { + name: "dut1" + vendor: OPENCONFIG + model: "LEMMING" +} +nodes: { + name: "dut2" + vendor: OPENCONFIG + model: "LEMMING" +} +nodes: { + name: "otg" + vendor: KEYSIGHT + version: "0.0.1-9999" # Please update this with the local version from ixiatg-configmap.yaml +} +links: { + a_node: "otg" + a_int: "eth1" + z_node: "dut" + z_int: "eth1" +} +links: { + a_node: "dut1" + a_int: "eth2" + z_node: "dut2" + z_int: "eth1" +}