Comment 2 for bug 1746483

Revision history for this message
Matt Riedemann (mriedem) wrote :

There are probably two ways to handle this:

1. Ignore the request in the IsolatedHostsFilter if the RequestSpec.image(.id) isn't set.

2. In the API code, if creating a server from a bootable volume, and no image id is provided, get the image id from the volume image metadata like this:

https://github.com/openstack/nova/blob/2ecb99939ec15057904d1b86c4478def29e193db/nova/compute/api.py#L2971

And then store that on the request spec. However, that might be confusing later if code assumes that an image id in the request spec means it wasn't a boot-from-volume request; although we do have utility code to tell if an instance is boot-from-volume, like here:

https://github.com/openstack/nova/blob/2ecb99939ec15057904d1b86c4478def29e193db/nova/compute/api.py#L2957

Option #2 is probably the more correct, albeit complicated, fix.