Remove "node" parameter from methods handling power state in docs

This patch fixes the doc about methods handling power state
to remove the parameter "node".
* validate
* get_power_state
* set_power_state
* reboot

Change-Id: I5c0425e1502f304b62566aa1e63823214888ef66
Partial-Bug: #1312632
Pass kwargs to ClientWrapper's call() method

As the ClientWrapper class had no unittests some were added to test
the specific part of the code for this change. The FakeClient() and
associated classes from test_driver.py were moved to a common file to
make it easier to be imported and used by the new unittests.

Partial-bug: #1316549
Related-bug: #1309719
Change-Id: I11be25a6ce981e63027073d12fbf2922896f4693
list_instances() to return a list of instances names

Previously the list_instances() method in the Nova Ironic driver was
returning a list of instances UUIDs instead of a list of instances names
causing various checks throughout nova.compute.manager to always return
False for Ironic.

Closes-Bug: #1309719
Change-Id: I0ed29911f180f99a7e2b1c00ddd6c43064f04f7f
Fix tests with new keystoneclient

A number of changes with keystoneclient breaks our tests. First, a
kwarg changed for cache.set(). It should be 'time' now, not 'timeout'.

Also: keystone middleware now looks for an 'expires' in the token.

Sample conf needed regenerated, also, due to changes.

Change-Id: I33c4f1bae5a3c89b47fd21f8db1b4a4d536ed369
Closes-bug: 1324655
Merge "Remove "node" parameter from methods handling power state in docs"
Merge "Pass kwargs to ClientWrapper's call() method"
Merge "list_instances() to return a list of instances names"
Factoring out PXE and TFTP functions

Multiple drivers need to support neutron and Ironic's PXE and TFTP
server. Factoring them out into a common file will make that
transition possible. I've moved all the generic calls into neutron
and reconfigured the PXE driver to work with the new functions.

Change-Id: I181ffabe673636b628329592e623e6425da54d6d
(cherry picked from commit d439265024187f38293f8507753c1ec5ebd60e1f)
Adding a reference driver for the agent

This driver handles communication with the Ironic Python Agent's REST
API and controls the agent through the deploy and tear down process.
It utilizes the nodeless vendor driver passthru to communicate with
newly booted agents. Things not included yet are support for
Neutron, agent registration/discovery, and writing an image to the
drive before deploy is called.

The original source for this driver was on GitHub. For history,
check: https://github.com/rackerlabs/ironic-teeth-driver

Depends on:
https://review.openstack.org/#/c/81391/
https://review.openstack.org/#/c/81919/

Implements: blueprint agent-driver
Change-Id: Ic6ad8703304af3041c48e9ade32eccbffa78ec9c
(cherry picked from commit f4eb7b850bb28a371f4ee2378b49461d96c9b489)
Drivers determine acceptable power states

The list of acceptable power states for a Node to be in when Nova is
calling deploy, update, and destroy were set globally.
This patch allows the deploy drivers to determine
which states are acceptable for each. I added a new validate
method to the DeployInterface class that can be overriden if
a driver determines it needs different settings (such as the agent
driver). The current function provides sane defaults and the
same behavior as before for any driver not overriding the function.

Change-Id: Iefec4396c323d9746bb0ee84b015765a4adbb476
Closes-Bug: 1306202
(cherry picked from commit 139c3f11988fe261eda92392a12853dceac63708)
Adding swift temp url support

This patch will allow properly configured Glance servers to return a temporary
URL for an object hosted on Swift. It will require Glance to use Swift
as its backend. A temporary URL will let the agent download an image from
Glance without requiring an auth_token, which gives access more than just
Glance. The easiest way to use it is to enable direct_url in Glance, but
you can set the appropriate config options to avoid needing to enable it.

We/I need to add a note in the docs about Swift being a possible dependency
for Ironic deploys using IPA, along with how to set the Temp URL key.

Swift perfomance concerns will be addressed in this blueprint:
https://blueprints.launchpad.net/ironic/+spec/improve-swift-agent-downloads

SecurityImpact
DocImpact

Implements: blueprint swift-temp-urls
Change-Id: I10e4784eee63e8edc9ba30a9c5004a08aa3a6d8e
(cherry picked from commit 9f919de4f6776fbcc93fdc9d3ff5bb1fe6b24e85)