There is no validation for PUT on update roles volume-mapping data
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Fuel for OpenStack |
Fix Released
|
Medium
|
Unassigned | ||
6.1.x |
Won't Fix
|
Medium
|
MOS Maintenance | ||
7.0.x |
Fix Released
|
Medium
|
Unassigned |
Bug Description
Problem:
There is no any validation for put operation to update role volume mapping. It is leads to broken disk conf in UI:
Remote Address:[::1]:8999
Request URL:http://
Request Method:GET
Status Code:500 Internal Server Error
list index out of range
[7fb84763f740] (node) Traceback (most recent call last):
File "/usr/lib/
attrs.volumes = instance.
File "/usr/lib/
return VolumeManager(self)
File "/usr/lib/
self.
File "/usr/lib/
space = find_space_
File "/usr/lib/
return filter(lambda space: space.get('id') == space_id, spaces)[0]
IndexError: list index out of range
Steps to reproduce:
Over fuel cli:
Setup master node
SSH to the master node
Download to file controller role with command:
fuel role --rel 2 --role controller --file controller.yaml
Modify created file: change "id" value at the "volumes_
Save file and upload it to the nailgun with:
fuel role --rel 2 --role controller --update --file contr.yaml
Over Api:
curl -s -H "X-Auth-
curl -s -X PUT -H "X-Auth-
Expected Result:
400 bad request
[root@nailgun ~]# cat /etc/fuel/
VERSION:
feature_groups:
- mirantis
production: "docker"
release: "6.1"
openstack_
api: "1.0"
build_number: "525"
build_id: "2015-06-
nailgun_sha: "dbd54158812033
python-
astute_sha: "1ea8017fe88894
fuel-library_sha: "2e7a08ad9792c7
fuel-ostf_sha: "8fefcf7c464937
fuelmain_sha: "a3998372183468
[root@nailgun ~]#
tags: | added: module-nailgun |
tags: | added: tech-debt |
Changed in fuel: | |
status: | Confirmed → In Progress |
Related patch-set: https:/ /review. openstack. org/#/c/ 193812