diff options
author | Volodymyr Mytnyk <volodymyrx.mytnyk@intel.com> | 2019-04-08 09:26:31 +0000 |
---|---|---|
committer | Gerrit Code Review <gerrit@opnfv.org> | 2019-04-08 09:26:31 +0000 |
commit | 1a6f868947011bf3ed4af87555bf2da55aadeac2 (patch) | |
tree | 82491b9bb93a5175acc2b1931f3952508c90b750 /yardstick/benchmark/contexts/heat.py | |
parent | ff2093ffa0279e91cf09c1f6843c473a0a1ff129 (diff) | |
parent | 489a6064839920121866f8fb3d3a86ab86e5e663 (diff) |
Merge "Update to support using external heat template"
Diffstat (limited to 'yardstick/benchmark/contexts/heat.py')
-rw-r--r-- | yardstick/benchmark/contexts/heat.py | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/yardstick/benchmark/contexts/heat.py b/yardstick/benchmark/contexts/heat.py index 403562c46..917aa9c39 100644 --- a/yardstick/benchmark/contexts/heat.py +++ b/yardstick/benchmark/contexts/heat.py @@ -509,6 +509,14 @@ class HeatContext(Context): server.private_ip = self.stack.outputs.get( attr_name.get("private_ip_attr", object()), None) + + # Try to find interfaces + for key, value in attr_name.get("interfaces", {}).items(): + value["local_ip"] = server.private_ip + for k in ["local_mac", "netmask", "gateway_ip"]: + # Keep explicit None or missing entry as is + value[k] = self.stack.outputs.get(value[k]) + server.interfaces.update({key: value}) else: try: server = self._server_map[attr_name] |