9066 Commits

Author SHA1 Message Date
Lars Kellogg-Stedman
70d7bb369a honor ipmi_port in serial console drivers
teach the ipmitool driver about _get_ipmitool_args and use that in all
cases that we want to build an ipmitool command line.   this solves
the problem that the serial console drivers were failing to honor the
ipmi_port setting in driver_info, while it was being correctly used
for power state, etc.

Change-Id: Ifbf6a92c2305567985cfbc41dbf76a076ecb8a7b
Story: 2005138
Task: 29826
2019-03-13 11:00:12 +01:00
Zuul
edb5a60331 Merge "Allocation API: optimize check on candidate nodes" 2019-03-11 16:25:00 +00:00
Zuul
68afa6d8e6 Merge "Stop requiring root_gb for whole-disk images" 2019-03-11 16:17:31 +00:00
Zuul
f681fa682e Merge "driver-requirements: mark UcsSdk as Python 2 only" 2019-03-11 10:06:46 +00:00
Zuul
63d852a46b Merge "Fix typo and docstring in pxe/ipxe" 2019-03-11 07:37:58 +00:00
Harald Jensås
13bdf8b0ca Fix typo and docstring in pxe/ipxe
The docstring contains parameter mode which is not
present. Move the param description to a comment
in code where mode is resolved.

Also fixes a typo in pxe_utils.py docstring.

Change-Id: Ic0a31612023a4985178dbb6e3078dff53f0aba0a
2019-03-08 18:56:55 +01:00
Zuul
02df7f7288 Merge "Add option to set python interpreter for ansible" 2019-03-08 17:48:00 +00:00
Dmitry Tantsur
40b55416a8 Stop requiring root_gb for whole-disk images
This parameter makes no sense for them and is actually ignored after
validation. This change makes it optional (still allowed for backward
compatibility). Also cleanly separate validation code for partition and
whole-disk images.

Change-Id: I98da7d54cc6dd158d415e83c61659badc83fbeda
Story: #2005165
Task: #29895
2019-03-08 14:01:27 +01:00
Marcin Juszkiewicz
442376a7c2 driver-requirements: mark UcsSdk as Python 2 only
Change-Id: Ia89f11861f100e08430f0e8a46276d1fc03ba53d
2019-03-08 10:44:30 +01:00
Riccardo Pittau
c8ece0c625 Add option to set python interpreter for ansible
This patch adds the option to configure the python interpreter
that is used when deploying machines using the ansible deploy
interface.

Also set the default interpreter for tinyipa image with
ansible deploy interface to /usr/bin/python3 on devstack
and marks ironic-standalone job as voting again.

Change-Id: I8eb58fb00980c9e8946e3b3ef77611a9f5212668
Story: #2005159
Task: #29877
2019-03-07 18:40:06 +01:00
Dmitry Tantsur
77ee49f21c Document using a URL for image_checksum
Added in https://review.openstack.org/#/c/639079/

Change-Id: I82800ba5c3379634f6f2583933f37aa4da60c33a
Story: #2005061
Task: #29770
2019-03-07 11:08:26 +01:00
Zuul
faf0bccbb0 Merge "Fix TypeError: __str__ returned non-string (type ImageRefValidationFailed)" 2019-03-07 04:41:20 +00:00
Zuul
e8bf85e7dd Merge "Allow building configdrive from JSON in the API" 2019-03-07 03:30:49 +00:00
Zuul
d8cc4c9f7c Merge "Drop installing python-libvirt system package" 2019-03-07 01:50:09 +00:00
Riccardo Pittau
790530f337 Temporary marking ironic-standalone non-voting
The ironic-standalone job is failing because the most recent IPA
image has only python3 and ansible uses python 2 as default
interpreter, resulting in a /usr/bin/python not found error.
Marking ironic-standalone non voting and removing it from the
gate until we can run ansible with python3 on remote machines.

Change-Id: I56768d7c8a577f267172de02d77e2cc2ead785ad
2019-03-06 17:00:11 +01:00
Dmitry Tantsur
3e1e0c9d5e Allow building configdrive from JSON in the API
Extend the API with the ability to build config drives from meta_data,
network_data and user_data, where meta_data and network_data are JSON
objects, and user_data is either a JSON object, a JSON array or
raw contents as a string.

This change uses openstacksdk (which is already an indirect dependency)
for building config drives.

Change-Id: Ie1f399a4cb6d4fe5afec79341d3bccc0f81204b2
Story: #2005083
Task: #29663
2019-03-05 19:14:56 +01:00
Zuul
5d25189b13 Merge "Add option to protect available nodes from accidental deletion" 2019-03-05 14:21:08 +00:00
Zuul
a17b20d125 Merge "Update the log message for ilo drivers" 2019-03-05 05:31:02 +00:00
Dmitry Tantsur
885bfbda96 Allocation API: optimize check on candidate nodes
Currently we fetch all nodes one by one when validating the provided
candidate_nodes. This is not overly efficient, so this change introduces
a new database API to specifically validate a list of names/uuids and
convert it to uuids. As a nice side effect, no database query is done
for identities that cannot be a valid node name or uuid.

Change-Id: I7adfe897200b1b05d9e632c68d0d3d046c06a921
Story: #2004341
2019-03-04 14:52:14 +01:00
Dmitry Tantsur
245af384ff Fix TypeError: __str__ returned non-string (type ImageRefValidationFailed)
This change contains two fixes for the same issue:
* Do not pass an instance of ImageRefValidationFailed as a message
  to an exception constructor.
* Make sure that IronicException.__str__ always returns an str,
  even when a non-string is passed as the first argument to __init__.

Change-Id: I96edb28955e64915e9d6a481634857fd27690555
Story: #2003682
Task: #26206
2019-03-04 13:16:17 +01:00
Mark Goddard
ec2f7f992e Deploy templates: API & notifications
Adds deploy_templates REST API endpoints for retrieving, creating,
updating and deleting deployment templates. Also adds notification
objects for deploy templates.

Bumps the minimum WSME requirement to 0.9.3, since the lower constraints
job was failing with a 500 error when sending data in an unexpected
format to the POST /deploy_templates API.

Change-Id: I0e8c97e600f9b1080c8bdec790e5710e7a92d016
Story: 1722275
Task: 28677
2019-03-04 10:30:16 +00:00
Mark Goddard
17a944fe9d Deploy templates: conductor
Adds the conductor-side logic required to map an instance's requested
traits to zero or more deploy templates. The steps defined in those
deploy templates are combined and added to deployment steps from the
driver interfaces, and used when provisioning the node.

The deploy steps for a node that come from deploy templates are
validated during node validation, and when deploying a node.

Change-Id: Ic4ac7926a1eaeb8b84d4f9f1af23bbe54554f250
Story: 1722275
Task: 28675
2019-03-04 10:00:07 +00:00
Zuul
3f6d4c6a78 Merge "Test API max version is in RELEASE_MAPPINGS" 2019-03-04 02:39:50 +00:00
Jens Harbott
296480961d Drop installing python-libvirt system package
Pip will install libvirt-python later in the process and with pip >= 10
it will fail to remove the system version.

Change-Id: I33be5426ce8ff2301d28096af11a1023b8048a15
Needed-By: https://review.openstack.org/#/c/561597
2019-03-01 17:40:51 +00:00
Zuul
8721924115 Merge "Deploy templates: fix updating steps in Python 3" 2019-03-01 16:44:56 +00:00
Mark Goddard
c121709575 Test API max version is in RELEASE_MAPPINGS
This should catch the case where the API version has been updated but
release mappings has not (or vice versa).

Change-Id: I62183d329c0efe9fe3bd47a0ca478155075b3230
2019-03-01 14:13:08 +00:00
Zuul
84f6e5fb84 Merge "Adding bios_interface reference to api docs" 2019-03-01 11:08:48 +00:00
Nisha Agarwal
51b67c4416 Update the log message for ilo drivers
This patch updates the log message for ``ilo``
drivers and extends the warning to Gen9 as well.
The proliantutils fix which added active NIC inspection
for Gen9 has been reverted back in
I02c27d820b27bd532f23ab7ef276b39f868f5205

story: #2004950
task: #29366

Change-Id: Ifbffb782c10b952bfb3498b882f07d313d410356
2019-03-01 00:34:35 -08:00
Zuul
b277be27a9 Merge "Deprecate Cisco drivers" 2019-02-28 18:49:36 +00:00
Mark Goddard
e989a21f06 Deploy templates: fix updating steps in Python 3
If a step in a deploy template is updated, changing only the step's
'args' field, then we see the following error on Python 3:

TypeError: unorderable types: dict() < dict()

In Python 3, dicts are no longer orderable, so cannot be used as part of
the key to a sort function. This change uses a JSON dump of the step
with sorted keys for comparison, as suggested in [1].

[1] https://stackoverflow.com/a/22003440

Change-Id: I70b806d5850f0678f3dd6633228947f6cd39d691
Story: 1722275
Task: 29750
2019-02-28 12:11:13 +00:00
Mark Goddard
db94e35745 Fix pysendfile requirement marker
Currently, any patch that changes one of the requirements files is
failing the requirements-check job, with the following error:

Requirement(package='pysendfile', location='', specifiers='>=2.0.0',
markers='', comment='# MIT', extras=frozenset()) 'markers': '' does not
match "sys_platform!='win32'"

Could not find a global requirements entry to match package {}. If the
package is already included in the global list, the name or platform
markers there may not match the local settings.

The problem is that a "sys_platform!='win32'" marker was added [1] to
the pysendfile requirement in the requirements repo, which needs to be
propagated to the requirements of all repos using the package.

This change adds the required marker to requirements.txt.

[1] https://review.openstack.org/#/c/639084/

Change-Id: Ibd7656cbcfbf204930f9c8562f79ab92bd4aefb5
Story: 2005096
Task: 29697
2019-02-28 09:56:26 +00:00
Arne Wiebalck
885ddb4362 Add option to protect available nodes from accidental deletion
Ironic allows to delete nodes which are in state 'available'.
As bringing nodes into 'available' comes at an operational cost
(i.e. enroll, inspect, clean, ...), this patch proposes a new
option 'allow_deleting_available_nodes' to support the protection
of available nodes against accidental removal.

Change-Id: I08d31b5ddbad626811c971389e634a450aeaf066
Story: #2005060
Task: #29604
2019-02-27 20:50:17 +00:00
Zuul
1e4a1cb7cb Merge "Add check for object versions" 2019-02-27 19:15:09 +00:00
Zuul
a52f615d92 Merge "Trivial: Fix error message when waiting for power state" 2019-02-27 12:00:02 +00:00
Zuul
6afb2906bd Merge "Deploy Templates: add 'extra' field to DB & object" 2019-02-27 05:57:57 +00:00
Zuul
3da6ed5b5b Merge "Deploy Templates: Fix DB & object nits" 2019-02-27 05:39:05 +00:00
Mark Goddard
a105ee0943 Deploy Templates: add 'extra' field to DB & object
The original patch [1] to add DB & object support for deploy templates
did not include an 'extra' field for metadata. This patch adds the
field, and bumps the object version.

Change-Id: I95b4beae217704defc9eab851780fd9c42847c40
Story: 1722275
Task: 29698
2019-02-26 15:54:51 +00:00
Arne Wiebalck
9e8464346b Trivial: Fix error message when waiting for power state
The power states already contain the word 'power', so currently
an error reads:
"Timed out after 30 secs wating for power power off on node ..."

Change-Id: I2535c15172df475a7d08c5219c2b97690ea67a58
2019-02-26 13:41:18 +00:00
Dmitry Tantsur
08270cebab Allocation API: fix minor issues in the API reference
Follow-up to commit acc4c402de42be0b1fb179d13dcf86a4ca384206.

Change-Id: Ie519caf791b6444afdc5a8665b1fbd719f916388
Story: #2004341
2019-02-26 11:13:07 +01:00
Zuul
ba83855111 Merge "Allocation API: reference documentation" 2019-02-26 10:01:59 +00:00
Dmitry Tantsur
acc4c402de Allocation API: reference documentation
Change-Id: I48f20f0b96931a17c477b9687b0ee963cb7b8879
Story: #2004341
Task: #29574
2019-02-26 10:16:25 +01:00
Zuul
fc9a989c28 Merge "Set available_nodes in tempest conf" 2019-02-25 18:54:29 +00:00
Zuul
8701cd069a Merge "[trivial] Removing python 3.5 template jobs" 2019-02-25 16:17:49 +00:00
Riccardo Pittau
e0639875f4 Adding bios_interface reference to api docs
As per title, this patch adds default_boot_interface and
enabled_boot_interfaces references, definitions and examples
to the api-ref documentation.

Change-Id: I35d4829c32cc48d5734c269c0a83ad9b4fbdd660
2019-02-25 17:09:11 +01:00
Zuul
a0ddb8c3ea Merge "Update the proliantutils version in documentation" 2019-02-25 14:41:20 +00:00
Jakub Libosvar
a9d7d8fd99 Set available_nodes in tempest conf
The patch sets the available_nodes config option in tempest.conf
that is consumed by the ironic multitenancy tests.

Needed-By: https://review.openstack.org/639098
Change-Id: Id8087375088180174247370d129f78cc06b1d49e
2019-02-25 15:10:21 +01:00
Zuul
6a96bfa57e Merge "Follow up to node description" 2019-02-25 06:03:42 +00:00
Nisha Agarwal
b9f7cf59f8 Update the proliantutils version in documentation
Update the proliantutils version from 2.7.1 to 2.8.

story: #2004950
task: #29366

Change-Id: Iaa915ed3aced57153db468d8ccd9d87f9e5728ac
2019-02-24 21:55:31 -08:00
Zuul
cffd49ef35 Merge "Allocation API: taking over allocations of offline conductors" 2019-02-22 19:10:16 +00:00
Riccardo Pittau
578805b34b [trivial] Removing python 3.5 template jobs
Also correcting docs as we don't have a py35 environment

Change-Id: I409db4b73a2dedf283107708e7eea105549da867
2019-02-22 12:21:25 +01:00