Enable VM DHCP request to reach DHCP agent

When using the firewall driver IptablesFirewallDriver and the
default INPUT and FORWARD rules are DISCARD then the DHCP
request from the VM is discarded prior to getting to the dnsmasq.

A new rule will be added that enables DHCP requests to pass.

This fixes bug 1131223

Change-Id: I50fad5b63c3c4b22a5d828e3e89353c1ed723332
Clean unused kernels and ramdisks from image cache

Fixes bug #1132138

Only unused disk images are currently cleaned up by the image cache
manager but it seems logical to clean up unused kernels and ramdisks
too.

Achieve that by writing kernels and ramdisks to disk using the sha1
sum of their ID as the filename. This is the same scheme as used for
disk image filenames and causes the image cache manager to consider
them for cleanup. We also make the cache manager take note of in use
kernels and ramdisks when iterating over the list of instances.

A nasty upgrade concern is that if we immediately switch to writing
kernels to disk using this scheme then, where shared storage is used,
we can have older image cache managers on remote compute nodes cleaning
up kernels because they appear unused. To mitigate that, turn off this
behaviour by default and allow it to be enabled using a new config
option. This option will be removed in future and the behaviour enabled
by default.

DocImpact: new remove_unused_kernels option

Change-Id: I56bba9fa6596601104498e262c2e657f0eae2fa0
Readd run_tests.sh --debug option.

Testr doesn't directly support running tests with pdb so the --debug
option was pulled from run_tests.sh during the testr switch. Add the
flag back into run_tests.sh and have it run tests with testtools.run
which allows users to import pdb in tests then run them without
interference from testr.

Example usage:
  # First edit test file to import pdb.
  run_tests.sh -d path.to.test

If the test is not given on the command line all tests will be run.

Change-Id: I4afca9ca997ccb6c575b714b778a9db8306c7891
Imported Translations from Transifex

Change-Id: I797e5f89c636b9619d5cb1862316f3c33d04b606
Change nova-dhcpbridge FLAGFILE to a list of files

This patch adds support to linux_net and nova-dhcpbridge for
specifying and conveying multiple dhcpbridge_flagfile values.
The support is implemented as follows:

dhcpbridge_flagfile is now a "MultiStr" configuration file option
allowing the flag files to be defined over multiple configuration files.
The configured files are concatenated into a comma separated string and
assigned to the FLAGFILE environment variable when invoking
nova-dhcpbridge. nova-dhcpbridge splits the value of the environment
variable on the comma an initializes its configuration with the provided
files (the configuration system already supports loading configuration
from multiple files)

Fixes bug 1131932

Change-Id: Ic9cc57b8f7d9356606b9134ef5b63ab07b6099d9
Merge "Clean unused kernels and ramdisks from image cache"
Merge "Imported Translations from Transifex"
Merge "Readd run_tests.sh --debug option."
if reset fails, display the command that failed

we get failures in _reset_databases from time to time, and it's
hard to debug without understanding what command failed. Make
this show up in the assert message.

Now with even more output!

Change-Id: Ie82109cfb1745e7218e0906764db1fad0c8fc5f5
Fix broken baremetal migration tests

Change 1c5518ba introduced different user/passwd for the baremetal CI
tests, which did not match the CI systems. Since then, all the baremetal
migration tests have been skipped or failing.

This patch sets the user/passwd back to 'openstack_citest'.

Change-Id: I88508d83d6e9e63f20c26704ec6b455c48a33e8f
Fix incorrect zookeeper group name

The zookeeper driver group name is 'zookeeper' not 'zk'.

Change-Id: I346cb2740ea835d17918f46be7ca142957537626
Minor code optimization in _compute_topic

In cases where a valid host is passed, the if
statement is always executed twice, not once like it should

Change-Id: I6a24bb4f85bfb94d2fdc5d1652ee371f296a10ef
Merge "Change nova-dhcpbridge FLAGFILE to a list of files"
Merge "Enable VM DHCP request to reach DHCP agent"
Fix hacking.py to handle 'cannot import x'

Fix missingImport logic to handle a module that cannot be imported, due
to a missing dependant module.

Due to the nature of this bug doctests cannot cover it.

Fix bug 1133103

Change-Id: Ia067bacc125b67e2d9e0cfc72495e4f13a8648ad
Merge "Fix hacking.py to handle 'cannot import x'"
Merge "if reset fails, display the command that failed"
Merge "Minor code optimization in _compute_topic"