sync_power_states handles missing driver info

The ConductorManager._sync_power_states() periodic task will stop
checking power states if getting the power state of a node raises an
exception. Eg, this could happen if a node is not properly configured
(for which node.driver.power.validate() raises an exception).

With this change, sync_power_state catches the exceptions, logs them,
and continues checking other nodes.

Change-Id: I343f722de8f79a50fbaa9fcdd180decdc5a43f95
Closes-Bug: #1262912
Use same MANAGER_TOPIC variable

In ironic/conductor, manager.py and rpcapi.py both specify the variable
MANAGER_TOPIC = 'ironic.conductor_manager'.

They have to have the same value because this is the rabbit topic that
they communicate over. It would be less error-prone (and more obvious
that they should be the same), if it was only specified in one place.

Since cmd/conductor.py uses MANAGER_TOPIC from manager.py, rpcapi.py
was modified to do the same.

Change-Id: I5875ffb7548c1b5079ac4221ce1000ae620509d8
Closes-Bug: #1268810
Replace assertTrue with explicit assertIsInstance

assertIsInstance can provide useful message when test fails,
this patch replaces assertTrue(isinstance(x, y)) with
assertIsInstance(x, y).

Change-Id: Ia87b6b8d15f96ce7cf4082fc5ec599ade1d8114e
Closes-Bug: #1268480
Use oslo.rootwrap library instead of local copy

Remove rootwrap code copied from oslo-incubator, make the
ironic-rootwrap console_script entrypoint point to oslo.rootwrap
code instead.

Patch based on: https://review.openstack.org/#/c/67422

Change-Id: I3dd2c4cab6652dea5bd755b6048cbeea9edc81cf
Partial-Bug: #1268674
Add missing "Filters" section to the ironic-images.filters

The ironic-images.filters file is missing the [Filters] section. This
will cause the ironic-rootwrap command to fail.

Change-Id: I3780fc89e0144093a40035e6b91fcf946bbdf6a3
Partial-Bug: #1268674
Fix non-unique pxe driver 'instance_name'

The driver 'instance_name' property was used to determine
the image directory name for the instance's image storage.
Since there is no guarantee that the intance_name will be unique,
we will use node uuid.

Change-Id: I781424215bdeb5372ceef2d6f11737e8f003054d
Closes-Bug: #1236536
Fix non-unique tftp dir instance_uuid

The driver 'instance_uuid' property was used to determine
the tftp directory name for the instance's images.
Since there is no guarantee that the intance_uuid will be unique,
we will use node uuid.

Change-Id: Ie8422b39eb6007b833d09be1855874a82dcb17d4
Imported Translations from Transifex

Change-Id: I383c12d5d132d67606d8d9ea7004b035c952ff91
Delete the iscsi target

After writing the image on the disk and logout the iscsi session,
we also need to delete that session to cleanup things, making sure it
doesn't appear as an available iscsi node to connect to.

Partial-Bug: #1261644
Change-Id: I05115e1a66974244e03020652b560829884ebaac
Merge "Fix non-unique pxe driver 'instance_name'"
Merge "Fix non-unique tftp dir instance_uuid"
Merge "Replace assertTrue with explicit assertIsInstance"
Remove unused config option - pxe_deploy_timeout

This is a vestigial config option left over from nova-bm refactoring, which is not used.

Change-Id: Iede8e2935ccfcb4706ec61fc5ee2991dc5c334e2
Closes-Bug: 1270981
Merge "Use same MANAGER_TOPIC variable"
PXE instance_name is no longer mandatory

With the use of node.uuid as the property to build the directory
name for the instance images, instance_name is not longer needed
to validate the pxe driver info.

Change-Id: I1839bcd5bf0ca0f3d6e62d5760ede65c1ec3e8e8
Remove the absolute paths from ironic-deploy-helper.filters

The commands might be located in a different directories on different
distros, so this patch is removing the absolute paths in the
ironic-deploy-helper.filters file.

Change-Id: I68873a04acbf1519165f758b1803f12ba9ddf777
Closes-Bug: #1268696
Run mkfs as root

The mkfs command requires root permission to write the filesystem on
certain devices. This patch is adding the run_as_root=True flag for the
execute() in the mkfs() function in common/utils.py, and is also adding
the mkfs to the rootwrap filters.

Closes-Bug: #1271243
Change-Id: I44e21c287510f355907fa45cbcb14b7f8c493a96
Add comment about node.instance_uuid

Add a comment explaining why we don't store instance_uuid
in node.properties. This came up in conversation, and it seems
good to record it for future reference.

Change-Id: I26ea0154c22daa83888bc56ea2a4a052705f5a96
Updated from global requirements

Change-Id: I37ca5a3e5599ca5836d4ff612430dfe548385de6
Add [keystone_authtoken] to ironic.conf.sample

Update the auto-generation of our sample config file by exporting a
variable to oslo.config.generator such that it will include the
keystone_authtoken section when building our config.

Change-Id: I8f0d93846cd948059ac6cbc6ec4024257e2c3f27
Closes-bug: 1271308