Libvirt: allow more than one boot device

This patch makes use of the boot_index information of block devices to
allow libvirt to boot from devices other than disks, and have more than
one boot device.

It does so by calculating the boot devices based on block devices type
and boot index, and then assigning the correct list to the GuestConfig's
os_boot_dev (that was made into a list in
I38abe9edaa8f93469d58ad81a466f68c2c0d24d6).

Closes-bug: 1229327
Change-Id: Ic33894cb818ee7c44579e6d00f273b40f669aa9b
Fix nova DB 215 migration script logic error

This addresses a minor (albeit important) logic error in the migration script
for https://review.openstack.org/#/c/46379/ - that script currently deletes
compute node stats for active compute nodes.  This patch reverses that logic
so it deletes the correct set of compute node stats.

Also included is a migration test case to demonstrate the behavior.

Change-Id: I77afcf443357d0767ac933d791a565289eabee9a
Closes-Bug: #1238281
Merge "Libvirt: allow more than one boot device"
Merge "Fix nova DB 215 migration script logic error"
XenAPI: Fix translation of metadetails in aggregates

https://review.openstack.org/#/c/43157/ added a translation from the sqlalchemy model to
the instance object replacing metadetails with metadata.

This added more traces in general for XenAPI (when we queried whether we were using
aggregates) and actually broke the host aggregate functionality

Change-Id: I87195753931945b6e1ecf75bc81575a6fa03068e
Closes-bug: 1232179
xenapi: post install scriptlet to rpm

A freshly installed XenServer requires some modifications in order to be
able to run OpenStack. Nova contains an rpm specification to create a
package with the dom0 plugins, however installing the rpm is not enough.
Some more actions need to be taken:
 - create /images, link to a directory within the local SR
 - setup an ssh keypair, and authenticate it with the host
This change adds a post script to the nova plugins rpm spec file, so
by installing the rpm on a XenServer, it is ready to run OpenStack, no
further manual actions needed.

Change-Id: Id57e3a3ab2782550468c6aa4c01059ceb7cc81ab