diff options
author | mbeierl <mark.beierl@dell.com> | 2017-12-20 15:14:14 -0500 |
---|---|---|
committer | Mark Beierl <mark.beierl@dell.com> | 2017-12-22 17:16:13 +0000 |
commit | 577bb77e605f78934260d6578bf07fb5071f3354 (patch) | |
tree | e54ecd902e9b82e99e3de30a514a61ed95383f5f | |
parent | 97b9772dcaa915ffe4b5cc427535816e139a1479 (diff) |
Fixes Availability Zone Supportstable/euphrates
Fixes typo and passes the availability zone parameter
through all the heat templates.
Change-Id: I12d9d5d32ceb6461833fcfb4ea2961a34b97c35a
JIRA: STORPERF-225
Signed-off-by: mbeierl <mark.beierl@dell.com>
(cherry picked from commit 9100f1afcc426b387dee3673151786680bfe0718)
4 files changed, 10 insertions, 6 deletions
diff --git a/docker/storperf-master/rest_server.py b/docker/storperf-master/rest_server.py index 7bcd650..9280721 100644 --- a/docker/storperf-master/rest_server.py +++ b/docker/storperf-master/rest_server.py @@ -173,7 +173,7 @@ class Configure(Resource): if ('volume_size' in request.json): storperf.volume_size = request.json['volume_size'] if ('availability_zone' in request.json): - storperf.availabilty_zone = request.json['availability_zone'] + storperf.availability_zone = request.json['availability_zone'] if ('username' in request.json): storperf.username = request.json['username'] if ('password' in request.json): @@ -186,9 +186,9 @@ class Configure(Resource): return jsonify({'agent_count': storperf.agent_count, 'agent_flavor': storperf.agent_flavor, 'agent_image': storperf.agent_image, + 'availability_zone': storperf.availability_zone, 'public_network': storperf.public_network, 'volume_size': storperf.volume_size, - 'availability_zone': storperf.availability_zone, 'stack_id': storperf.stack_id}) except Exception as e: diff --git a/docker/storperf-master/storperf/resources/hot/agent-group.yaml b/docker/storperf-master/storperf/resources/hot/agent-group.yaml index c758ecd..3c02e31 100644 --- a/docker/storperf-master/storperf/resources/hot/agent-group.yaml +++ b/docker/storperf-master/storperf/resources/hot/agent-group.yaml @@ -33,7 +33,9 @@ parameters: constraints: - range: { min: 1, max: 512 } description: must be between 1 and 512 agents. - + availability_zone: + type: string + default: nova resources: slaves: @@ -49,6 +51,7 @@ resources: agent_network: {get_resource: storperf_network}, flavor: {get_param: agent_flavor}, image: {get_param: agent_image}, + availability_zone: {get_param: availability_zone}, storperf_open_security_group: {get_resource: storperf_open_security_group}, key_name: {get_resource: storperf_key_pair}, volume_size: {get_param: volume_size} diff --git a/docker/storperf-master/storperf/resources/hot/storperf-agent.yaml b/docker/storperf-master/storperf/resources/hot/storperf-agent.yaml index 9f0481e..7841e8c 100644 --- a/docker/storperf-master/storperf/resources/hot/storperf-agent.yaml +++ b/docker/storperf-master/storperf/resources/hot/storperf-agent.yaml @@ -39,11 +39,11 @@ parameters: type: string constraints: - custom_constraint: neutron.network - agent_zone: + availability_zone: type: string default: nova -resources: +resources: storperf_agent: type: "OS::Nova::Server" properties: @@ -55,7 +55,7 @@ resources: - port: { get_resource: storperf_agent_port } user_data: { get_resource: storperf_agent_config } user_data_format: RAW - availability_zone: { get_param: agent_zone} + availability_zone: { get_param: availability_zone} storperf_agent_config: type: "OS::Heat::CloudConfig" diff --git a/docker/storperf-master/storperf/storperf_master.py b/docker/storperf-master/storperf/storperf_master.py index 6879e75..36ce04b 100644 --- a/docker/storperf-master/storperf/storperf_master.py +++ b/docker/storperf-master/storperf/storperf_master.py @@ -503,6 +503,7 @@ class StorPerfMaster(object): heat_parameters['volume_size'] = self.volume_size heat_parameters['agent_image'] = self.agent_image heat_parameters['agent_flavor'] = self.agent_flavor + heat_parameters['availability_zone'] = self.availability_zone return heat_parameters def _attach_to_openstack(self): |