Enable $pybasedir value in pxe.py

We should not refer $pybasedir directly in our python code, because
it is loaded by paths.py, we should use paths.basedir_def("") to load
this $pybasedir value as a base path.

And change some 'nova' words to 'ironic in paths.py

Change-Id: I4c6bcb103d4d1eee8e7bf78f46c815630666cfe9
Closes-Bug: #1267351
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
PXEAndSSH driver lacked vendor_passthru

Add vendor_passthru interface to PXEAndSSHDriver
to allow PXE-based deploys to continue.

Change-Id: Ief087f75b0b6975ed2b461f46cddcc9067316efe
Closes-bug: 1268066
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
Fix keystone get_service_url filtering

We are retrieving the services from keystone, so there
is no need to do filtering of the catalog, since we are
directly dealing with services endpoints.

Change-Id: I9a40207e2dee2e5bc268b9516daa74a3c6cf2352
Merge "PXEAndSSH driver lacked vendor_passthru"
Add RPC method for node maintenance mode

Method 'change_node_maintenance_mode' added to manager and rpcapi.
This method triggered maintenance mode for a node.
New column 'maintenance' added to nodes table.

Partial-Bug: #1260099
Change-Id: I945a1ce72c04e5ee2a9427a58dae72b0719c160f
Disallow new provision for nodes in maintenance

New deploy operation will not allowed for nodes in
'maintenance' mode.

Partial-Bug: #1260099
Change-Id: Idaf8c3d70bd78b2c95bbdcff734e235eb8063d91
Merge "Enable $pybasedir value in pxe.py"
Merge "Fix keystone get_service_url filtering"
Merge "Add RPC method for node maintenance mode"
Merge "Disallow new provision for nodes in maintenance"
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'"