glance image-create with invalid store fails but still creates image
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Glance |
Fix Released
|
Medium
|
Yanis Guenane |
Bug Description
glance checks whether or not a specified store is valid, but if it is invalid the image has already been created.
I pulled the latest devstack code and then ran these commands after sourcing openrc:
ubuntu@
ID Name Disk Format Container Format Size
-------
6792e9a7-
7808c034-
4efcddb2-
ubuntu@
ubuntu@
curl -i -X POST -H 'x-image-
HTTP/1.1 400 Bad Request
date: Thu, 12 Dec 2013 12:47:37 GMT
content-length: 52
content-type: text/plain; charset=UTF-8
x-openstack-
400 Bad Request
Store for scheme s3e not found
Request returned failure status.
400 Bad Request
Store for scheme s3e not found
(HTTP 400)
ubuntu@
ID Name Disk Format Container Format Size
-------
b26c03e4-
6792e9a7-
7808c034-
4efcddb2-
This problem occurs using the v1 API. If using the V2 API the '--store' option does not seem to be present.
Changed in glance: | |
assignee: | nobody → Yanis Guenane (yanis-guenane) |
status: | New → Confirmed |
Changed in glance: | |
importance: | Undecided → Medium |
Changed in glance: | |
milestone: | none → icehouse-3 |
Changed in glance: | |
status: | Fix Committed → Fix Released |
Changed in glance: | |
milestone: | icehouse-3 → 2014.1 |
This happens because the validity of the --store parameter is never checked, only the scheme's value in the location (ie. s3://toto -> s3)