diff options
Diffstat (limited to 'yardstick/orchestrator/heat.py')
-rw-r--r-- | yardstick/orchestrator/heat.py | 28 |
1 files changed, 21 insertions, 7 deletions
diff --git a/yardstick/orchestrator/heat.py b/yardstick/orchestrator/heat.py index 455ddc34e..d58ae5618 100644 --- a/yardstick/orchestrator/heat.py +++ b/yardstick/orchestrator/heat.py @@ -497,7 +497,7 @@ name (i.e. %s).\ 'type': 'OS::Neutron::SecurityGroup', 'properties': { 'name': name, - 'description': "Group allowing icmp and upd/tcp on all ports", + 'description': "Group allowing IPv4 and IPv6 for icmp and upd/tcp on all ports", 'rules': [ {'remote_ip_prefix': '0.0.0.0/0', 'protocol': 'tcp', @@ -508,7 +508,20 @@ name (i.e. %s).\ 'port_range_min': '1', 'port_range_max': '65535'}, {'remote_ip_prefix': '0.0.0.0/0', - 'protocol': 'icmp'} + 'protocol': 'icmp'}, + {'remote_ip_prefix': '::/0', + 'ethertype': 'IPv6', + 'protocol': 'tcp', + 'port_range_min': '1', + 'port_range_max': '65535'}, + {'remote_ip_prefix': '::/0', + 'ethertype': 'IPv6', + 'protocol': 'udp', + 'port_range_min': '1', + 'port_range_max': '65535'}, + {'remote_ip_prefix': '::/0', + 'ethertype': 'IPv6', + 'protocol': 'ipv6-icmp'} ] } } @@ -518,11 +531,10 @@ name (i.e. %s).\ 'value': {'get_resource': name} } - def add_server(self, name, image, flavor, flavors, ports=None, - networks=None, scheduler_hints=None, user=None, - key_name=None, user_data=None, metadata=None, - additional_properties=None): - """add to the template a Nova Server""" + def add_server(self, name, image, flavor, flavors, ports=None, networks=None, + scheduler_hints=None, user=None, key_name=None, user_data=None, metadata=None, + additional_properties=None, availability_zone=None): + """add to the template a Nova Server """ log.debug("adding Nova::Server '%s', image '%s', flavor '%s', " "ports %s", name, image, flavor, ports) @@ -537,6 +549,8 @@ name (i.e. %s).\ 'flavor': {}, 'networks': [] # list of dictionaries } + if availability_zone: + server_properties["availability_zone"] = availability_zone if flavor in flavors: self.resources[name]['depends_on'].append(flavor) |