From ffe83c920736716f0caea36dceeff7b7e910db7c Mon Sep 17 00:00:00 2001 From: JingLu5 Date: Mon, 3 Jul 2017 10:34:53 +0000 Subject: support segmentation_id for vlan provider network If a network specified in the test case is a vlan provider network, new attribute "segmentation_id" can be used to specify the desired vlan tag in the test case network section: networks: test-net: cidr: '192.168.1.0/24' provider: "vlan" physical_network: 'physnet1' segmentation_id: "1000" If the "segmentation_id" attribute is absent, a random vlan tag will be allocated to the network. Change-Id: Ic53852447a3c1bd8feb9ebd42d35f1ade3684be1 Signed-off-by: JingLu5 --- yardstick/benchmark/contexts/model.py | 1 + 1 file changed, 1 insertion(+) (limited to 'yardstick/benchmark/contexts/model.py') diff --git a/yardstick/benchmark/contexts/model.py b/yardstick/benchmark/contexts/model.py index 1f8c6f11c..5077a9786 100644 --- a/yardstick/benchmark/contexts/model.py +++ b/yardstick/benchmark/contexts/model.py @@ -107,6 +107,7 @@ class Network(Object): self.router = None self.physical_network = attrs.get('physical_network', 'physnet1') self.provider = attrs.get('provider', None) + self.segmentation_id = attrs.get('segmentation_id', None) if "external_network" in attrs: self.router = Router("router", self.name, -- cgit 1.2.3-korg