5338 Commits

Author SHA1 Message Date
OpenStack Proposal Bot
bedfbf311b Updated from global requirements
Change-Id: I886421684ea169cd7a45dbe4441df5ffdd1272a1
2016-08-04 02:35:37 +00:00
Jenkins
761dadba73 Merge "Fix for "db type could not be determined" error message" 2016-08-04 01:17:12 +00:00
Jenkins
a260bdd6e9 Merge "Migrate to using keystoneauth Sessions" 2016-08-04 01:17:03 +00:00
Jenkins
6385d2d695 Merge "Extend the "configuring ironic-api behind mod_wsgi" guide" 2016-08-03 21:39:19 +00:00
Jenkins
8a6f714b2e Merge "Update nova scheduler_host_manager config docs" 2016-08-03 21:29:51 +00:00
Jenkins
7cfbb96d21 Merge "Updating dev quickstart to include compatiblity for newest distros" 2016-08-03 21:05:55 +00:00
Jenkins
7a88711e4b Merge "Devstack should use a prebuilt ramdisk by default" 2016-08-03 21:05:39 +00:00
Varun Gadiraju
288f4e617b Fix for "db type could not be determined" error message
If tests are run under py27 then run under py34 or py35, user may get
`db type could not be determined` error.

This patch adds a note to the dev-quickstart guide telling user to
remove the file `.testrepository/times.dbm` and then run the py34 or
py35 test to work around this error.

Change-Id: I57b583eaa8586d14cee730eefc515ad064ac8b32
Closes-Bug: #1229445 (regarding Ironic)
2016-08-03 19:23:34 +00:00
Pavlo Shchelokovskyy
f9ea26ebf3 Migrate to using keystoneauth Sessions
We currently construct Keystone client objects directly, which
is no longer the preferred way.  Instead, we should be using Sessions
which allows use of different auth plugins.  This change attempts to
migrate our Keystone usage to this model.

Additionally, we currently rely on the imported keystonemiddleware
auth_token's configuration for all of the Keystone credentials used
by the Ironic service user.  This is bad, as that config is internal
to that library and may change at any time.  Also, the service user
may be using different credentials than the token validator.

This refactors the keystone module to use Sessions.
It attempts to provide some backward compat for users
who have not yet updated their config,
by falling back to the authtoken config section when required.

Operators impact:

- Authentification parameters for each service now should specified in
  the corresponding config section for this service ([glance], [neutron]
  [swift], [inspector]).
  This includes providing both Keystone session-related options
  (timeout, SSL-related ones) and authentification options
  (`auth_type`, `auth_url` and proper options for the auth plugin).

- New config section `service_catalog` for Ironic service user
  credentials, used to resolve Ironic API URL from Keystone catalog.

- If loading from the service config section fails, an attempt is made
  to use respective options from [keystone_authtoken] section as a
  fall-back for backward compatibility.

Implementation details:

- using keystoneauth1 library instead of keystoneclient

- For each service the keystone session is created only once and is
  reused further. This lowers the number of authentification requests
  made to Keystone but implies that only auth plugins that can
  re-authentificate themselves can be used (so no *Token plugins).

This patch does not update the DevStack plugin, in order to test
backwards compatibility with old config options.
DevStack plugin will be modified in a subsequent patch.

Change-Id: I166eebefc1e1335a1a7b632149cf6441512e9d5e
Closes-Bug: #1422632
Related-Bug: #1418341
Related-Bug: #1494776
Co-Authored-By: Adam Gandelman <adamg@ubuntu.com>
2016-08-03 11:24:21 -07:00
Jenkins
bf4788cc1d Merge "Pass agent metrics config via conductor" 2016-08-03 18:19:27 +00:00
Akilan Pughazhendi
be8577b32c Updating dev quickstart to include compatiblity for newest distros
Updates ironic dev quickstart to include compatability with the
latest versions of python, ubuntu and fedora

Change-Id: I14b0668e228c47db36970df14a774469f6d966d1
Closes-bug: 1603575
2016-08-03 15:56:16 +00:00
Jenkins
4bd6e9793d Merge "Move default network_interface logic in node object" 2016-08-03 13:02:18 +00:00
Jim Rollenhagen
ced53d561f Update nova scheduler_host_manager config docs
Nova no longer allows the full python path to the host manager class.
Update the docs to be correct.

Change-Id: I54f203399dff5c9496516d9260e5f43bcc47b022
2016-08-03 08:11:44 -04:00
Lucas Alvares Gomes
bacc872b72 Extend the "configuring ironic-api behind mod_wsgi" guide
The etc/apache2/ironic configuration have the logs file path pointing to
/var/log/apache2/ which does not exist in the Red Hat systems (the
equivalent is /var/log/httpd). This patch extend the documentation to
point that out to the operator to look at these paths when setting up
the ironic-api to run behing Apache mod_wsgi.

Related-Bug: #1608252
Change-Id: I591748245af885eeb782df82eaa5f33e123f8e06
2016-08-03 11:35:00 +01:00
Jenkins
863ffe984c Merge "Timing metrics for agent deploy classes" 2016-08-03 05:17:20 +00:00
Jenkins
49b5027158 Merge "Minor docstring and unittests fixes for IPMIConsole" 2016-08-02 22:51:52 +00:00
Jay Faulkner
92edcabcf8 Timing metrics for agent deploy classes
This change adds timing metrics for all agent deploy classes. The only
methods we are not emitting metrics for are those that return static
results.

Change-Id: I96290be44a60635f3bd68e7a43549e2f67a19f12
Related-bug: #1526219
2016-08-02 12:30:46 -07:00
Jay Faulkner
84bf48431c Pass agent metrics config via conductor
This adds agent config options for metrics as described in the
spec, and allows those config options to be sent to IPA on
lookup. We're configuring heartbeat timeout this way, and this
change matches nicely with that style.

Additionally, this sets heartbeat_timeout under the new config
namespace for consistency, however, we'll allow the old way to
be deprecated when the vendor_passthru for agent lookups is
deprecated.

Change-Id: I94d81b95feabe46999dbbc02522508cd542a89f8
Co-Authored-By: Josh Gachnang <josh@pcsforeducation.com>
Partial-bug: #1526219
2016-08-02 17:56:43 +00:00
Dao Cong Tien
c81bd9e5c7 Minor docstring and unittests fixes for IPMIConsole
This is the follow-up patch of the commit
857372a2269cdd0f8a1ae5b9e9f6e0ee193f01be. This fix follows
some minor comments of Lucas and Ruby from patch set 29 at the
review: https://review.openstack.org/#/c/293873/. The changes are:

* Fix the docstring of the _start_console() in ipmitool.py to reflect
  the real parameters being passed to the method.

* Fix few unittests to use self.assertFalse(<mock>.called) instead of
  self.assertFalse(<mock>.call_count)

Change-Id: I25caa9202c8bc867973205d2bf9642064d3ba492
2016-08-02 16:30:22 +00:00
Jenkins
88303cc56c Merge "Add support for the audit middleware" 2016-08-02 15:16:27 +00:00
Jenkins
c705000992 Merge "Use 'UUID', not 'uuid' in exception strings" 2016-08-02 14:26:10 +00:00
Jim Rollenhagen
cedff4e378 Move default network_interface logic in node object
This patch moves the default network_interface logic into the node
object using a field default value. This means if the network_interface
on a node object is ever set to None it'll calculate the default to
place into that field.

Change-Id: I753d969b31ba2d12df4db3fc95a7d9e9ca1e4df6
Partial-Bug: #1608511
2016-08-02 15:25:14 +01:00
Jenkins
dfcb6568fb Merge "Implement new heartbeat for AgentDeploy" 2016-08-01 17:56:41 +00:00
Jenkins
c6e40cf902 Merge "Support to validate iLO SSL certificate in iLO drivers" 2016-08-01 17:29:08 +00:00
Jenkins
66b66fd629 Merge "Fix rendering for version 1.14" 2016-08-01 11:33:42 +00:00
OpenStack Proposal Bot
10ba46f3d5 Updated from global requirements
Change-Id: I95f3c5a83940db310048592cdbe7444f9f3b5034
2016-07-30 01:18:28 +00:00
Jenkins
c35ba34707 Merge "Centralize config options - [agent]" 2016-07-30 00:20:22 +00:00
Jay Faulkner
5b752d258a Devstack should use a prebuilt ramdisk by default
Ironic-python-agent has both supported ramdisks prebuilt and ready for
download, leaving no reason for building this in devstack in the general
case.

This also resolves (via alternative means) the bug which is causing our
deploy ramdisk to get built every time in the gate.

Change-Id: I00cf31bf75343fec4d7ec11178b3a253da806ac0
Related-bug: #1607981
2016-07-29 16:03:26 -07:00
Jenkins
1ecafaaa87 Merge "Log full config only once in conductor" 2016-07-29 00:26:23 +00:00
Ramamani Yeleswarapu
46fcfb3199 Centralize config options - [agent]
Nova style refactor of config options in Ironic.

Change-Id: I97d3a616ca8b68a74d4ad546f81f3a94ce4bad2a
Partial-Bug: #1561100
2016-07-28 16:19:46 -07:00
Jenkins
8be3bf4bf4 Merge "Add node.resource_class field" 2016-07-28 16:50:30 +00:00
Pavlo Shchelokovskyy
ae6e628b2d Log full config only once in conductor
oslo.service's wait() already does that for us.

Change-Id: I66b6a8c8daf32948badde555b12d2f0f9cd88c8a
2016-07-28 19:07:31 +03:00
Jim Rollenhagen
f16c6570bf Add node.resource_class field
This adds the "resource_class" field to the node table, object, and API,
as well as a database migration to go with it.

Change-Id: I936f2e7b2f4d26e01354e826e5595ff021c3a55c
Partial-Bug: #1604916
2016-07-28 11:49:27 +00:00
Jenkins
fe62ee82be Merge "Add api-ref for new port fields" 2016-07-28 09:32:19 +00:00
Vladyslav Drok
395069cbef Add api-ref for new port fields
API microversions 1.18, 1.19 introduced new fields in Port resource,
this change adds them to api-ref documentation.

Partial-bug: #1526403

Change-Id: Ib7059fd1ec8ffc54fa34647cc558fb8c8e80f8d7
2016-07-27 18:24:25 +00:00
Jenkins
246e886dde Merge "Change comment regarding network_interface" 2016-07-27 12:36:10 +00:00
Lokesh S
295b35c48f Add support for the audit middleware
This adds support for the audit middleware to Ironic, allowing
the middleware to send two notifications per API request,
one for the request and another for the response.
This adds an option to enable or disable audit middleware.
Also to properly audit API requests passing conf options
via audit map file.

AuditMiddleware docs:
   http://docs.openstack.org/developer/keystonemiddleware/audit.html

Co-Authored-By: Chris Krelle <nobodycam@gmail.com>

Closes-Bug: #1540232
Change-Id: I6de4751aa6b25e8457cae3eeab95a15f417662c5
2016-07-26 11:43:35 -07:00
Jenkins
f7bfa3ee73 Merge "Remove unused code when failing to start console" 2016-07-26 15:56:19 +00:00
Vladyslav Drok
641ab43e3e Change comment regarding network_interface
In order to be able to unittest older API versions without changing
tests that do node post, let's only add network_interface field to
the return value of node_post_data if it was explicitly requested.

Change-Id: I6de525040ee83011d3ebaf3e6da714bd3cd30603
2016-07-26 18:00:02 +03:00
Jenkins
7e80ab8f22 Merge "Centralize config options - [deploy]" 2016-07-26 11:13:04 +00:00
Jenkins
6b8daf9f24 Merge "Centralize config options - [api]" 2016-07-26 11:08:58 +00:00
Ruby Loo
7706af37e0 Fix rendering for version 1.14
The description for version 1.14 is rendered incorrectly.
A blank line is added so that the two bullets are rendered
correctly.

Change-Id: I52fcbf51dd4b42c832e3ae65aefdf8ddea405492
2016-07-25 20:37:17 -04:00
Jenkins
636f26ad1a Merge "IPMITool: add IPMISocatConsole and IPMIConsole class" 2016-07-26 00:05:22 +00:00
Jenkins
0051d0e0f2 Merge "Use assertEqual() instead of assertDictEqual()" 2016-07-25 18:18:27 +00:00
Jenkins
d4e8e0f071 Merge "Trivial: Fix a trivial flake8 error" 2016-07-25 18:18:12 +00:00
Jenkins
b3f0355046 Merge "Remove duplicate copyright." 2016-07-25 18:14:47 +00:00
Jenkins
cd146248d9 Merge "Bug fixes and doc updates for adoption" 2016-07-25 17:05:58 +00:00
Ruby Loo
c5a7385242 Use 'UUID', not 'uuid' in exception strings
Use the grammatically correct 'UUID' (since it is an
abbreviation) in exception strings.

Change-Id: Ib840b649b6ba0a7ba8dc935be6f06b9d36bb87d7
2016-07-25 11:10:39 -04:00
Yuiko Takada Mori
857372a226 IPMITool: add IPMISocatConsole and IPMIConsole class
IPMISocatConsole is a new console interface class using ipmitool and
socat. It has the same APIs of IPMIShellinaboxConsole class and
provides TCP4/TCP6 connection service to connect serial-on-LAN of
nodes.
IPMIConsole is a new console interface class using ipmitool and used
as parent class of IPMIShellinaboxConsole and IPMISocatConsol class.

This patch set implements new console driver interfaces
IPMISocatConsole.

To use PXE + IPMItool + socat, specify pxe_ipmitool_socat.
To use IPA + IPMItool + socat, specify agent_ipmitool_socat.

Spec: https://review.openstack.org/#/c/319505/
Partial-Bug: #1553083
Change-Id: I35a7dcb7e89baf16d096501fd44dbc12adc8c61e
2016-07-25 16:42:31 +09:00
Tang Chen
cd88db1f7e Use assertEqual() instead of assertDictEqual()
In unittest2, assertDictEqual() is implemented by
using != operator to compare two dicts. So is
assertEqual() in testtools. assertEqual() in testtools
is able to handle dict, list, set and so on. So we
just call assertEqual() to make the unit tests simpler.

Change-Id: I862fcc3665ed7efc17ce92afd8224134e0124f6e
2016-07-25 10:49:25 +08:00