Create ResourceGroup with volumes only if it is required
If volumes_per_node or volumes_size is 0, there is no sense in creating empty ResourceGroup. Also remove volumes from one node group in gate to be sure that sahara correctly handle such case. Closes-bug: 1494650 Change-Id: Ic592710773b9338f5857e431b0567bc5c87af2bd
This commit is contained in:
parent
ea993f12c2
commit
2b25dfa07f
@ -18,8 +18,6 @@ clusters:
|
||||
node_processes:
|
||||
- datanode
|
||||
- jobtracker
|
||||
volumes_per_node: 2
|
||||
volumes_size: 1
|
||||
auto_security_group: true
|
||||
cluster_template:
|
||||
name: fake01
|
||||
|
@ -310,7 +310,8 @@ class ClusterStack(object):
|
||||
}
|
||||
})
|
||||
|
||||
resources.update(self._serialize_volume(ng))
|
||||
if ng.volumes_per_node > 0 and ng.volumes_size > 0:
|
||||
resources.update(self._serialize_volume(ng))
|
||||
|
||||
return resources
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user