Remove unused 'get_open_port' method from libvirt utils

As of the following commit:

  commit 71410724cd1516608ee58c37077bf9080da38de2
  Author: Thierry Carrez <thierry@openstack.org>
  Date:   Tue Feb 7 16:37:34 2012 +0100

    Remove ajaxterm from Nova

The 'get_open_port' method in the libvirt utils.py module
is no longer used. Thus is can be deleted

Change-Id: I837d07f82d55c54b4abd82d9bb20498a1f489f84
Signed-off-by: Daniel P. Berrange <berrange@redhat.com>
Remove duplicate volume_id

Remove duplicate key 'volume_id' in a for loop in _update_block_device_mapping
in nova.compute.api

Change-Id: I43e51cb077334818abea0c1d3bdda4b761406ea4
Run hacking tests as part of the gate.

Nova has additional pep8 "plugins" that they expect to run as part of the
gate. This patch will run tools/hacking.py instead of pep8 directly. Also,
it fixes the hacking violaions in contrib, plugins and smoketests.

Fixes bug 1010136

Change-Id: I86d8789218c197d5d4a43d1201465d340646a395
Add compatibility for CPU model config with libvirt < 0.9.10

Libvirt versions prior to 0.9.10 do not support the simpler
'mode' attribute for choosing CPU model. So with such libvirt
releases we must explicitly construct the guest CPU model
from the host capabilities info when mode=host-model. We
can not support mode=host-passthrough at all with these
earlier libvirt versions

This change can be reverted in the future, if the value of
the MIN_LIBVIRT_VERSION constant is increased to 0.9.10
or later

Fixes: bug #1003373
Implements: blueprint libvirt-xml-cpu-model
Change-Id: I3e55ffccf38be18454f810efeb5c201aab94ddb0
Signed-off-by: Daniel P. Berrange <berrange@redhat.com>
Merge "Remove duplicate volume_id"
use import_object_ns for compute_driver loading

Part of bp:virt-driver-cleanup

Convert to using import_object_ns which allows us
to import specific virt drivers as 'libvirt.LibvirtDriver'
instead of 'nova.virt.libvirt.libvirtDriver'.

Update testing to ensure this works with both short
names and long names (which need not be in the nova.virt
namespace).

Change-Id: I5eee3389c7719d5f361532b0eddaa249233283a5
Switch to common logging.

I only just moved logging from nova to common, so behavior should remain the same.

Change-Id: I1d7304ca200f9d024bb7244d25be2f9a670318fb
Add ServiceCatalog entries to enable Cinder usage

 * Part of of blueprint extract-nova-volumes
 * Adds usage of service catalog to ec2
 * Adds entries to auth.py
 * Implements tests for new authorization mods

Change-Id: I2efb375bbb130cde6a1ba119fa862ca45b126a1e
Expand HACKING with commit message guidelines

Add a 'Commit Messages' section to HACKING describing how a commit
message should be formed.

Change-Id: I29b69022dfbdac09523eaa5cef3fc1a4550a7c5f
Implement nova network API for quantum API 2.0

blueprint improved-nova-quantum-integration

This new network API depends on quantum v2.0 client to connect quantum server
via Quantum server API V2.0. This change implements the minimum set of methods
so that we can boot an instance with ip allocated by quantum server.

Change-Id: I34acbbf84dd8601db8143267c8cc41255a0c6d3f
Prevent file injection writing to host filesystem.

Fix bug 1015531, CVE-2012-3360, CVE-2012-3361

This patch prevents the file injection code from writing into the host
filesystem if a user specifies a path for the injected file that
contains '..'.  The check is to make sure that the final normalized path
that is about to be written to is within the mounted guest filesystem.

Signed-off-by: Russell Bryant <rbryant@redhat.com>
Signed-off-by: Pádraig Brady <pbrady@redhat.com>
Signed-off-by: Mark McLoughlin <markmc@redhat.com>

Change-Id: I658cd12fd319cee91eb9544cdf53c862c5d2c560
Merge "Run hacking tests as part of the gate."
Fix assertRaises(Exception, ...) HACKING violation

This managed to sneak in while tox wasn't gating on hacking tests

Change-Id: I2a41ccef740bc602af8819ce03013ce890ff24ce
Merge "Expand HACKING with commit message guidelines"
Fix nova-rpc-zmq-receiver

Logging broke with change to stdlib logging,
changed to openstack.common log.

Use of 'python -d' seems not to work with 'env', and unnecessary.

Change-Id: I428c56c612c7d9d043dab2d36b80beb6ca184d27
Merge "Fix assertRaises(Exception, ...) HACKING violation"
Merge "Fix nova-rpc-zmq-receiver"
Merge "use import_object_ns for compute_driver loading"
Modifies ec2/cloud to be able to use Cinder

 * Implements part of blueprint extract-nova-volumes
 * Pass more complete information from ec2api to volume
 * Remove old comment from test_cloud
 * Stops creating mapping on default volume/snap creation, as
   the mapping is automatically created on access

Change-Id: I55f4364940cd606b06ad39256462dc1c436e28f1
Add Cinder Volume API to Nova

 * Implements part of blueprint extract-nova-volumes
 * Adds Cinder API to Nova (nova/volume/cinder.py)
 * Add fake volume API to use for unit tests
 * Add specific Cinder ec2/test_cloud version

Signed-off-by: Anthony Young <sleepsonthefloor@gmail.com>
Signed-off-by: Vishvananda Ishaya <vishvananda@gmail.com>

Change-Id: Id56972e2388a94d184c64bfae9c70a1f2805738b