Commit Graph

472 Commits

Author SHA1 Message Date
Zuul 7a6af41a26 Merge "Deprecate ironic-inspector support" 2024-02-20 19:53:25 +00:00
Zuul 6b5a99ac6e Merge "Switch to snponly and stop copying the unused ipxe.pxe" 2024-02-19 15:42:09 +00:00
Dmitry Tantsur dcbf1d98b9
Deprecate ironic-inspector support
Switches to the built-in inspection by default and deprecates support
for ironic-inspector. The actual removal should happen after we get
inspection rules in since it's the last feature that is relevant for
bifrost.

Depends-On: https://review.opendev.org/c/openstack/ironic/+/907398
Change-Id: Id157d5ada2ff3f87f3f4d161423b1f3989f73194
2024-02-01 14:50:16 +01:00
Sharpz7 4529d48afe [codespell] Fixing Spelling Mistakes
This is the first in a series of commits to add support for codespell. This is continuning the process completed in ironic-python-agent.

Future Commits will add a Tox Target, CI support and potentially a git-blame-ignore-revs file if their are lots of spelling mistakes that could clutter git blame.

Change-Id: I41b2db35cdf21917ac20ed0866af3b9c94789f0b
2024-01-25 21:31:33 +00:00
Zuul 6065da92b1 Merge "Configure the new inspection implementation" 2024-01-25 11:26:44 +00:00
Dmitry Tantsur 9bf1fde62a fix keystone auth scope
Fixes bifrost so it utilizes:
* The admin role, instead of the long deprecated baremetal_admin
  role.
* Utilizes system scope and admin scoped access where needed
  for during installation self-test commands to execute
  as expected.
* The user utilized for inspector's keystone access
  now utilizes the "admin" role instead of the
  baremetal_admin role.

Closes-Bug: 2051168
Change-Id: I090520547846a7a8d85bd032a52d6da039761186
2024-01-24 13:02:24 -08:00
Dmitry Tantsur c1ac96ec87
Switch to snponly and stop copying the unused ipxe.pxe
See the Ironic change for reasoning:
4d13da9cc7

Change-Id: Ia7e227b0f53ebc0f0bd25b91960174685b8b72a9
2024-01-17 10:57:48 +01:00
Riccardo Pittau c64f6ba5c1 Uplift default Ansible version to 8.x
Change-Id: Iabb9f55b8dacc7ef9965ac60d67e70b60dd723c5
2024-01-09 09:35:18 +01:00
Dmitry Tantsur ea0b4ec50b
Configure the new inspection implementation
The ironic-inspector one is still the default at this point.

Change-Id: I431ced6496ca6dac078a240f653afd33256048f6
2024-01-05 15:13:56 +01:00
Zuul e15d7ade1c Merge "Configure static DHCP before automated cleaning" 2024-01-05 00:34:48 +00:00
Zuul a66596474f Merge "Drop support for rootwrap" 2024-01-05 00:25:32 +00:00
Dmitry Tantsur 05ee7f72ab
Drop support for Ubuntu Focal
Its Python 3.8 is not supported by any active version of Ansible.
Focal has been best-effort for a while already.

Change-Id: Id04f9b9835cc705716a797caa7beef2536027186
2023-12-19 13:17:10 +01:00
Dmitry Tantsur ab62784f22
Configure static DHCP before automated cleaning
After the switch to newer ansible collection, the enrollment workflow
started running automated cleaning (before that, it would use the old
API version resulting in immediate "available"). However, the static
DHCP configuration only happened in the inspect and deploy workflows,
which are run after enrollment.

This change extracts a new small role for the DHCP config and includes
it in all 3 workflows that use DHCP.

While here, make sure that dnsmasq_dhcp_hostsdir is respected.

Change-Id: Idf6f24dde11d600698d45a218812cba8134fb73f
2023-12-19 11:03:43 +01:00
Riccardo Pittau 35c3d51dc4 Update default ansible version
Uplift default Ansible version to 7.x

Change-Id: I98d240e2ec2c61e662647dc8b0159934ada18431
2023-12-15 09:53:20 +01:00
Dmitry Tantsur 0fd1e03907
Drop support for rootwrap
Change-Id: I2baf94feb79bad2f975b5b6e801979b0cabef1e5
2023-12-14 12:57:31 +01:00
Zuul 83066af17d Merge "Use sha256 instead of md5 by default" 2023-12-13 20:41:38 +00:00
Zuul 6537f7164f Merge "Switch IPA building to Debian Bookworm" 2023-12-13 20:41:37 +00:00
Zuul 2b8ae2d995 Merge "Fix disable-dhcp option in playbook" 2023-12-13 18:03:08 +00:00
Riccardo Pittau fe9541b6e9 Fix disable-dhcp option in playbook
The enable_dhcp variable is still pointing to the removed variable
include_dhcp_server while it should use enable_dhcp instead.

Change-Id: I60992fa7286766f4fac935e53207f49a98cd77cd
2023-12-11 16:50:48 +01:00
Dmitry Tantsur 954032d719
Switch IPA building to Debian Bookworm
Depends-On: https://review.opendev.org/c/openstack/ironic-python-agent-builder/+/903175
Change-Id: I7de7841c9fb16379cce94ce08413483472284534
2023-12-11 11:40:32 +01:00
Dmitry Tantsur f66cd939a2
Support for Debian Bookworm
Change-Id: Ia687d7652980da81f94b6a7644faa26354afc65b
2023-12-08 15:58:25 +01:00
Dmitry Tantsur 1a8dcd3e55
Use sha256 instead of md5 by default
Change-Id: I8564228e221919829541124c36baae60a874f1e5
2023-12-05 14:20:22 +01:00
Zuul e41ed49832 Merge "ironic: Perform online data migrations with localhost DB" 2023-11-17 20:57:08 +00:00
Mark Goddard d656492d4b ironic: Perform online data migrations with localhost DB
Previously online data migrations were not performed in the default
configuration where the database address is 'localhost'. I'm not sure
why this condition was used, but it was present in the original
change I685efd14bf3567a126311b676a50b0abb0f043db submitted adding the
online data migrations back in the Stein release.

This change removes the condition to perform online data migrations
regardless of the database address.

Change-Id: I60d0f61a3c6fd3573b2031f7dba5d8a29e178394
Closes-Bug: #2036772
2023-09-20 17:11:41 +01:00
Zuul 12462b8989 Merge "Fix for lack of log rotation in Bifrost" 2023-09-06 19:56:02 +00:00
Zuul 7a9e8b71bf Merge "Replace Cirros references with generic descriptors" 2023-09-05 17:05:38 +00:00
Rafal Lewandowski ce445f0967 Fix for lack of log rotation in Bifrost
Closes-Bug: #2033528
Change-Id: I7c2ba2b263dd84641674b60aed8971b129aa846f
2023-09-04 14:36:48 +02:00
Dmitry Tantsur 16b34f378d Remove Fedora from the CI
It is currently broken since the only supported version (36) is EOL.
The OpenDev infrastructure will stop supporting Fedora:
https://lists.opendev.org/archives/list/service-discuss@lists.opendev.org/thread/IOYIYWGTZW3TM4TR2N47XY6X7EB2W2A6/

The UEFI netboot job has been migrated to Stream 9.

Change-Id: Ie4e67491a62a4c6cb4ca9d6e700cfc226a121235
2023-08-21 09:45:52 +02:00
Matt Crees a6ce283146 Replace Cirros references with generic descriptors
Often it is beneficial to use the functionality provided by `use_cirros`
and `cirros_deploy_image_upstream_url` to download and test with images
of other OS distributions. This patch changes the variable names to
reflect that use case.

`use_cirros` -> `download_custom_deploy_image`
`cirros_deploy_image_upstream_url` -> `custom_deploy_image_upstream_url`

The functionality of the old variables is retained for backwards
compatability.

Co-Authored-By: Alex Welsh <alex@stackhpc.com>

Change-Id: I8b3a973bd5ef19333af563c170b2a28fbbfb5c76
2023-08-10 11:41:32 +01:00
Zuul 18712af740 Merge "Support PXE network boot with grub" 2023-01-26 10:50:51 +00:00
Zuul 29f31b22af Merge "Remove enable_uefi_ipxe" 2023-01-23 18:07:22 +00:00
vguillard bf1bb49c38 Feature: Enable user_data's file generation
This feature allow custom user-data's file generation by the user.
It is usefull for example when user needs to set up an advanced ssh configuration (special user, SSH certificate-based authentication)

Signed-off-by: vguillard <vincent.guillard@b-com.com>
Story: 2010475
Task: 47036
Change-Id: I2831e58d84f1da03485f8315eccdd2e79231e584
2023-01-19 10:51:21 +01:00
Steve Baker 51d988af54 Support PXE network boot with grub
It is now possible to do a PXE network boot with grub as an
alternative to iPXE. Grub is loaded via the signed shim, so it may
allow end-to-end automated deployments with secure-boot enabled.

To use grub network boot, deploy bifrost with variable
``default_boot_interface`` set to ``pxe``.

This feature is tested by job
bifrost-integration-redfish-uefi-fedora-latest.

test-bifrost.sh is also modified to only enable the hardware-type
driver which matches driver used for test nodes. This allows a default
interface to be set which is not supported by one of the enabled
drivers (for example, ironic will exit because the ilo driver doesn't
support the pxe boot interface)

Change-Id: I8ac33d0aa0f71b092d2c0538ac3a73491ff44921
2023-01-19 10:33:21 +13:00
Steve Baker 3218eb5891 Remove enable_uefi_ipxe
Parameter ``enable_uefi_ipxe`` has been removed, instead
``enabled_boot_interfaces`` is checked for containing ``ipxe``.

Change-Id: Id47d596750319d8e2889dff9741c6ef4e790ad56
2023-01-19 10:31:00 +13:00
Riccardo Pittau 4626648887 Move bifrost tests to Ubuntu Jammy
Leave ubuntu focal job defined for compatiblity with other projects
and older versions.

Change-Id: Idcfde886c9a92a5d09a07b1b8e88caa6a388f92a
2022-09-26 15:29:43 +02:00
Zuul 7a38657435 Merge "Rename include_dhcp_server -> enable_dhcp for consistency" 2022-09-21 15:24:50 +00:00
Dmitry Tantsur b3818dc77c Do not install grub2 and shim on the host system
At least on the CI nodes it causes issues with grub-pc on Debian since
the CI nodes don't have bootloader configured. Download and extract
packages instead.

To account for Kolla (which has a split between the install and the
bootstrap phases), the downloaded files are cached in /use/lib/ironic.

Change-Id: I9307366db9579b194dcb88818ed0ce2fedb4baaf
2022-09-16 17:58:01 +02:00
Dmitry Tantsur 059bd92b24 Rename include_dhcp_server -> enable_dhcp for consistency
Change-Id: Iff141df7adbe69775ce264d591be0466bd4a7e3b
2022-09-16 12:56:40 +02:00
Zuul 38b40461ca Merge "Fix TFTP read access for enforcing SELinux" 2022-09-02 19:23:29 +00:00
Zuul d6e6d647c7 Merge "Repair MariaDB tables after upgrade" 2022-08-03 12:49:18 +00:00
Mark Goddard da3b67819e Repair MariaDB tables after upgrade
Sometimes MariaDB changes the format of database tables between
releases. A mysql_upgrade tool is provided that will attempt to repair
the tables to make them compatible with the new version of MariaDB.

Upgrading from Ubuntu Focal 20.04 to Ubuntu Jammy 22.04 will trigger
such an issue:

  TASK [bifrost-ironic-install : MySQL - Creating user for Ironic]
  The user specified as a definer ('mariadb.sys'@'localhost') does not exist

This change runs mysql_upgrade after installing MariaDB.

Story: 2010208
Task: 45935

Change-Id: Iabcb8296489b0915bdb6a2a8a0de4dfe87853482
2022-08-02 17:17:05 +01:00
Steve Baker 0baff1e124 Fix TFTP read access for enforcing SELinux
This change adds ironic_tftp_master_path to the list of paths to get
the tftpdir_t context, so that images copied from here to
tftp_boot_folder will have a context which allows the file to be read.

This change also applies the context changes when SELinux is in
Permissive mode, as well as Enforcing.

Change-Id: I43dd4a2f7cf47934bc9f5cdee85acf53a40dd468
2022-08-01 12:38:03 +12:00
Zuul 49d48f729c Merge "Fix upgrade on CentOS and with Keystone enabled" 2022-07-18 18:40:49 +00:00
Zuul 8f85e01fe1 Merge "Test redeploy-dynamic when cirros/tinyipa are used" 2022-07-15 15:58:51 +00:00
Zuul 72bd174321 Merge "Deprecate os_ironic_node_info" 2022-07-15 14:22:41 +00:00
Dmitry Tantsur 03ddd02656 Fix upgrade on CentOS and with Keystone enabled
* Downgrade openstacksdk instead of the collections since some keystone
  code does not work on old collection and new SDK.
* Force checkout on upgrade since we have local changes to requirements

Reverts commit c12b7fafe8.

Change-Id: I14a83b703c1c76fd311c60aa23880b5708105165
2022-07-08 16:28:37 +02:00
Dmitry Tantsur d95a1fe078 Test redeploy-dynamic when cirros/tinyipa are used
This is a documented feature, we need to validate it.

Rename a variable to prevent it from clashing with one in the roles.

Pull cloud configuration to be able to work with TLS.

Change-Id: Ie41060dba2ae8c2dd88e0e6f9b574b7214302983
2022-07-08 15:56:49 +02:00
Dmitry Tantsur e9577408b6 Deprecate os_ironic_node_info
The OpenStack ansible collection provides baremetal_node_info.

Change-Id: I1c8a28666e7e52f838423a9e4c6aa8475728069d
2022-07-06 15:03:45 +02:00
Zuul 5a2f223ea5 Merge "Use Ansible 5.x" 2022-07-05 14:32:01 +00:00
Riccardo Pittau c3b700e2b3 Remove support for Python 3.6 and 3.7
We're not testing them since a while now, better be explicit

Change-Id: I9739d727fddde4f6f3d4cbef28591ea516715899
2022-06-16 17:37:35 +02:00