yahoo-eng-team team mailing list archive
-
yahoo-eng-team team
-
Mailing list archive
-
Message #49652
[Bug 1553152] Re: misleading API documentation for block_device_mapping_v2
** Changed in: nova
Status: Confirmed => Fix Released
--
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to OpenStack Compute (nova).
https://bugs.launchpad.net/bugs/1553152
Title:
misleading API documentation for block_device_mapping_v2
Status in OpenStack Compute (nova):
Fix Released
Status in openstack-api-site:
Fix Released
Bug description:
Documentation [1] about `block_device_mapping_v2` when creating a
server instance is misleading as it doesn't explain that it must
actually be an array of mappings and there is no complete list of the
supported keys. For example `volume_size` and `uuid` are not even
mentioned.
Thanks to an unrelated github bug [2] I figured it's something like this:
"block_device_mapping_v2": [
{
"boot_index": "0",
"uuid": "ac408821-c95a-448f-9292-73986c790911",
"source_type": "image",
"volume_size": "25",
"destination_type": "volume",
"delete_on_termination": true
}
The above example is something that very quickly gets you to the
point. In block_device_mapping.rst doc I see some of the things
explained but first I could only find that doc grepping nova's sources
and I still couldn't figure from that doc how in hell should I
construct my API call.
What I wanted to do is to basically launch an instance off a new
custom sized volume. That turned out very easy and conscious
eventually but finding that out took hours for me as I'm simply an API
user and I have no experience whatsoever installing, configuring, even
less hacking on OpenStack.
P.S. I'm using a similar feature in GCE. They have it even nicer. When
you specify the instance disks, it supports any options that are
supported by the api call creating a standalone disk. I guess values
are then passed to the disk api as is. Might be worth considering for
a future API version. e.g. at the moment I can't specify a name for
the new volume or many of the other options supported by the OS
volumes API.
[1] http://developer.openstack.org/api-ref-compute-v2.1.html#createServer
[2] https://github.com/ggiamarchi/vagrant-openstack-provider/issues/209#issuecomment-73961050
To manage notifications about this bug go to:
https://bugs.launchpad.net/nova/+bug/1553152/+subscriptions
References