* Update ironic-python-agent from branch 'master'
to b6075156b31281def5eb34deaf08676172c7ff97
- Merge "USB device discovery"
- USB device discovery
The idea is to retreive USB devices informations via 'lshw' and
return the list to ironic in order to be able to create introspection
rules based on USB devices.
Change-Id: I39d60cb467614fca7a7f701dbe576154213580a5
* Update ironic-python-agent from branch 'master'
to 8de6e03539be896d360b8355d4e602b9ae34d557
- Update ironic-lib min required version
The addition of the qemu-img module that is used in ipa was
introduced in ironic-lib 6.0.0
Change-Id: I65b283d9abcfe2aa961baf9f686391c8dcc71d6b
* Update ironic-python-agent from branch 'master'
to 783a0377ad2da5a486836edd54d3f623fc60751a
- Update master for stable/2024.1
Add file to the reno documentation build to show release notes for
stable/2024.1.
Use pbr instruction to increment the minor version number
automatically so that master versions are higher than the versions on
stable/2024.1.
Sem-Ver: feature
Change-Id: I67ee5ead4aa7f47517c35d1a77d594fcad22cc4c
* Update ironic-python-agent from branch 'master'
to ee8340f2cb7d2d23e0089b68da4851eaf0d8a29b
- Merge "Update regex to detect closed branch"
- Update regex to detect closed branch
... based on the change made in reno recently[1].
Also the overall regex is updated to be more consistent with the regex
used in ironic.
[1] https://review.opendev.org/c/openstack/reno/+/910547
Change-Id: I362de82fb5478b846df7a343da02a359f5f7dece
* Update ironic-python-agent from branch 'master'
to e28b3e72f79936c9151f2653f47d1fb0c38a4ea8
- Merge "Use assert_not_called"
- Use assert_not_called
IPA still has 3 occurences of not_called() which are failing for me
when building the Ironic Debian package in Debian Unstable (ie: with
Python 3.12).
This patch uses assert_not_called() instead of not_called(), fixing
the problem.
Change-Id: I8bd27fa706b298b28ef5bef405134a2c9803d757
* Update ironic-python-agent from branch 'master'
to 815e1f462f9cac0473699f06753e0850789061af
- Merge "reno: Update master for unmaintained/victoria"
- reno: Update master for unmaintained/victoria
Update the victoria release notes configuration to build from
unmaintained/victoria.
Change-Id: I00a9bcb8ee6d5160d2598fbecb8e585885212df7
* Update ironic-python-agent from branch 'master'
to aa76962b4e4e0635e195e419d9ea495d30661fb0
- Merge "reno: Update master for unmaintained/wallaby"
- reno: Update master for unmaintained/wallaby
Update the wallaby release notes configuration to build from
unmaintained/wallaby.
Change-Id: Iaf279482847d781d7d338c4923a672a5e9337332
* Update ironic-python-agent from branch 'master'
to 38ba0d8508f415c4b2618696797c10f9217a8b63
- reno: Update master for unmaintained/xena
Update the xena release notes configuration to build from
unmaintained/xena.
Change-Id: I3bbef10b65dc43596a59eaca5d792f5e451d5d4c
* Update ironic-python-agent from branch 'master'
to 9b760755cac8f65d4de7568c0d4e75a7bb385e7e
- Merge "Force constraints when installing a package during tox test"
- Force constraints when installing a package during tox test
The tox deps option grants installation of single dependencies and
requirements, optionally pinned using constraints, before installing
a package, therefore not granting installation of the correct
constraint during the package installation.
To fix that tox 4.4.0 has introduced the constrain_package_deps
option [1]
[1] https://tox.wiki/en/4.12.1/faq.html#using-constraint-files
Change-Id: I770e55db5d6f53174c490749d27830f9209e98cc
* Update ironic-python-agent from branch 'master'
to 95b3ed3fed0169f3c98593807465caabbe0dcdf9
- Fix unit tests after ironic-lib changes
Updating tests after change [1] and [2] in ironic-lib.
[1] ae53e8e4b3
[2] 7644196e7d
Change-Id: I880b4f82beb117d8812e60c13040e19476cec32b
* Update ironic-python-agent from branch 'master'
to 6d35c1e949b91510c655cf42e072ff45a062ba34
- Merge "Make inspection URL optional if the collectors are provided"
- Make inspection URL optional if the collectors are provided
With the new in-band inspection, we can derive the callback URL from
the Ironic URL, there is no need to duplicate it. This change uses
the presence of collectors as a sign to run inspection.
The previous approach of setting an inspection URL, with or without
explicitly setting collectors, still works for compatibility with
ironic-inspector.
Change-Id: Ie4279ee6d2995c9686f1dcdef1d6e5dc1dd20871
* Update ironic-python-agent from branch 'master'
to 614532d2a2db365c9801bbb858ecb1ddb01fcac3
- reno: Update master for unmaintained/yoga
Update the yoga release notes configuration to build from
unmaintained/yoga.
Change-Id: I0c5ab4348bd293ce77b04180247773412edbe179
* Update ironic-python-agent from branch 'master'
to 359ac636f06578466769866883971debd1861485
- Merge "Drop usage of run_as_root"
- Drop usage of run_as_root
IPA can only be run as root and does not use rootwrap. We need to
eventually remove support for rootwrap from ironic-lib.
Change-Id: Iffd5cae5e3dc8637bc6dd10b3bcc9fe33932b8cf
* Update ironic-python-agent from branch 'master'
to c3e3cf2aefd798a66d2aeff7b9af975d368c179b
- Merge "Also retry inspection on HTTP CONFLICT"
- Also retry inspection on HTTP CONFLICT
The new implementation can return it when unable to lock the node.
Other possible errors are 400 and 404 (should not be retried), as well as
5xx (already retried).
Change-Id: I74c2f54a624dc47e8e2d1e67ae4c6a6078e01d2f
* Update ironic-python-agent from branch 'master'
to 1e107bd625d1b1ddca6e2e2938a17e8595da9bb4
- Merge "Add support for reporting CPU socket number"
- Add support for reporting CPU socket number
IPA reports a few cpu fields including cores, arch, flags etc.
There is a need that user wants to utilize the physical number in
a baremetal since cores are just a logical representation of the
compute resource.
The socket number is more suitable for the quota control in some
use cases.
Change-Id: I94be86d6b12a3a7e7ca1041d948427a073412a31
* Update ironic-python-agent from branch 'master'
to b928b6601cd689c18b757494dd96b70e9f8c1297
- [Codespell] Adding tox target to CI (Non-Voting)
Adding CI for previous codespell tox change
Related Bug: https://bugs.launchpad.net/ironic-python-agent/+bug/2047654
Change-Id: I02f7973c0e6799f7d7b44978009dfebbce3877a4
* Update ironic-python-agent from branch 'master'
to be9477179bc8d02b35585437fa60e6629bebd630
- Merge "Support several API and Inspector URLs"
- Support several API and Inspector URLs
Allows nodes with a single IP stack to be deployed from a dual-stack
Ironic.
Detecting advertised address and usable Ironic URLs are done completely
independently which does open some space for a misconfiguration. I hope
it's not likely in the reality, especially since this feature is
targetting advanced standalone users.
Change-Id: Ifa506c58caebe00b37167d329b81c166cdb323f2
Closes-Bug: #2045548
* Update ironic-python-agent from branch 'master'
to 3e066e3f3ecc0d25295139f893256096937969cd
- Merge "Add missing headers to the inspection callback"
- Add missing headers to the inspection callback
Somehow, it has worked correctly for years, but now I've discovered that
the new inspection is (no longer?) tolerant to the missing header.
While here, copy all headers from the heartbeat code.
Change-Id: I9e5c609eb4435e520bc225dea08aedfdf169744b
* Update ironic-python-agent from branch 'master'
to dcf12d1b588c0bc0574c90c562158f2d37cf25cd
- Update python classifier in setup.cfg
As per the current release tested runtime, we test
till python 3.11 so updating the same in python
classifier in setup.cfg
Change-Id: I699e08c268040d387b91ccca4e6505184d3d1b59
* Update ironic-python-agent from branch 'master'
to 64081ad36be731c2f0ee5e199ba26bdb9cd38b25
- Merge "Remove deprecated pbr options"
- Remove deprecated pbr options
The api_doc_dir option and the autodoc_index_modules option were both
deprecated in pbr 4.2.
The required options for the sphinxcontrib-apidoc extension are already
defined in doc/source/conf.py .
Change-Id: Ifcef9e84ff4febeb01cfdc75bdbd66565d0e8079
* Update ironic-python-agent from branch 'master'
to dc33a97221c5dd3e8c0d9f6c08fd8b06e3e7336d
- Merge "Remove unnecessary egg_info options"
- Remove unnecessary egg_info options
The tag_svn_revision option was already removed[1]. The values set to
the other two options are effectively same as their defaults.
[1] https://github.com/pypa/setuptools/issues/619
Change-Id: I00c91a4966135a92ee6391b0b7084f2b5b04aaef
* Update ironic-python-agent from branch 'master'
to a22d1fc411639da4a896b5760df34de3ea78fc80
- Merge "Add tox target and configuration for codespell"
- Add tox target and configuration for codespell
Adds a tox target for codespell, `tox -e codespell`. Can optionally
be run as `tox -e codespell -- -w` to get automatic spelling fixes
applied where appropriate. Adds small amounts of configuration to
setup.cfg, including an ignore list of words.
Related-bug: #2047654
Change-Id: I98203b02a9c6b6fc36edd6b4bbcc7c92a634da8b
* Update ironic-python-agent from branch 'master'
to d298e06b4996f9efe41cee541e34d21a789d014b
- Merge "[codespell] Fix spelling issues in IPA"
- [codespell] Fix spelling issues in IPA
This fixes several spelling issues identified by codepsell. In some
cases, I may have manually modified a line to make the output more clear
or to correct grammatical issues which were obvious in the codespell
output.
Later changes in this chain will provide the codespell config used to
generate this, as well as adding this commit's SHA, once landed, to a
.git-blame-ignore-revs file to ensure it will not pollute git historys
for modern clients.
Related-Bug: 2047654
Change-Id: I240cf8484865c9b748ceb51f3c7b9fd973cb5ada
* Update ironic-python-agent from branch 'master'
to f1a4aeb29a924a06ae025ae3ea7560f462cd72de
- Merge "Update to latest pep8/code style versions"
- Update to latest pep8/code style versions
Update various linting programs to their latest version, and fix any
issues created by the update.
Change-Id: I014c846560663a76a1663b568ef48659d0ab6d4d
* Update ironic-python-agent from branch 'master'
to 7422a27de4e5cf8b622af8bf37bd4c5c300e943a
- Merge "Reformat and update the section on injecting root credentials"
- Reformat and update the section on injecting root credentials
Change-Id: I49ad9979daad11bf7a54069564c6b7919de0ea7c
* Update ironic-python-agent from branch 'master'
to 03b6b0a4ab36449efb94ce6cda65897b905f2bd0
- Fix inspector retries to not take a long time
Since we moved to exponential wait we increased the amount of time
to run unit tests, now we can configure the max time to wait
- before: Ran: 33 tests in 22.6581 sec.
- after: Ran: 33 tests in 4.0256 sec.
Change-Id: Ibdcfebacad0489d17183e43ceb0d603fce67e72b
* Update ironic-python-agent from branch 'master'
to 3a757f721f828ab85880c3c19eb428e8e86b6d29
- Merge "docs: improve rootpwd password generation command"
- docs: improve rootpwd password generation command
Currently the command is a bit misleading because you need to escape
dollar ($) signs.
Command copied from DIB dynamic-log element docs [1].
[1]: https://docs.openstack.org/diskimage-builder/latest/elements/dynamic-login/README.html
Change-Id: I7d5dc60aec373372f8faae4242a79f18d8a26d14
* Update ironic-python-agent from branch 'master'
to 2ab83646495e993940d14ec368c703854e6fb7f6
- Add a jitter to heartbeat retries
Currently, if heartbeat fails, we reschedule it after 5 seconds.
This is fine for the first retry, but it can cause a thundering herd
problem when a lot of nodes fail to heartbeat at once.
This change adds jitter to the minimum wait of 5 seconds. The jitter is
not applied for forced heartbeats: they still have a minimum wait of
exactly 5 seconds from the last heartbeat.
The code is re-ordered to move the interval calculation to one place.
Bonus: correctly logging the next interval.
The unit tests have been rewritten to test the heartbeat process step by
step and not rely on the exact sequence of the calls.
Closes-Bug: #2038438
Change-Id: I4c4207b15fb3d48b55e340b7b3b54af833f92cb5
* Update ironic-python-agent from branch 'master'
to 62041d6d9e3b029d522b1c21cfdcf4270835ac46
- Merge "Fix referencing to the raid_device var which is not set"
- Fix referencing to the raid_device var which is not set
Change-Id: I11180e5d61d893a78583ace555f6e90ba8845950
* Update ironic-python-agent from branch 'master'
to 801da9ec1ffcecb7b736f0c3c6476906b02b5443
- Retry in ProxyError during post inspector data
* ProxyError is derived from ConnectionError, but it's necessary
to check the Response object to identify.
- Added ProxyError in retry_if_exception_type
- Updated _post_to_inspector to proper handle ProxyError
- Updated the wait to use wait_exponential instead of wait_fixed.
Closes-Bug: 2045429
Change-Id: Iefe3fe581cd4e7c91a0da708e6f6d0fdaacab6fe
* Update ironic-python-agent from branch 'master'
to beccfe8c92a4db893b6a6dc05b132568fdb07030
- Merge "Revert "Fix vmedia network config drive handling""
- Revert "Fix vmedia network config drive handling"
This reverts commit 33f01fa3c2f32f447ed36f00fea68321c3991c2e.
There are a few issues with the patch - see my comments there.
The most pressing and the reasons to revert are:
1) It breaks deployments when the vmedia is present but does not
have a network_data.json (the case for Metal3).
2) It assumes the presence of Glean which may not be the case.
Neither Julia nor myself have time to thoroughly fix the issue,
leaving a revert as the only option to unblock Metal3.
Change-Id: I3f1a18a4910308699ca8f88d8e814c5efa78baee
Closes-Bug: #2045255
* Update ironic-python-agent from branch 'master'
to 61d17e2225938be84c9e15f6317e17235d2b04b9
- Merge "Parse efibootmgr type and details"
- Parse efibootmgr type and details
This change improves the regex to match an exact entry name, and to also
match with the the entry type from a set of recognised types.
The boot entry details start from the recognised type onwards.
This can be used by a step which deletes all entries of type 'HW' and
UsbClass.
Related-Bug: #2041901
Change-Id: I5d879f724efc2919b541fd3fef0f931df67ff9c7
* Update ironic-python-agent from branch 'master'
to eea9917023c082cc9681f7bfe20852df92eb01dd
- Merge "Fix vmedia network config drive handling"
- Fix vmedia network config drive handling
When performing DHCP-less deployments, the agent can start and
discover more than one configuration drive present on a host.
For example, a host was previously deployed using Ironic, and
is now being re-deployed again.
If Glean was present in the ramdisk, the glean-early.sh would end
mounting the folder based upon label.
If cloud-init, somehow is still in the ramdisk, the other folder
could somehow get mounted.
This patch, which is intended to be backportable, causes the agent
to unmount any configuration drive folders, mount the most likely
candidate based upon device type, partition, and overall state of
the machine, and then utilize that configuration, if present,
to re-configure and reload networking.
Thus allowing dhcp-less re-deployments to be fixed without
forcing any breaking changes.
It should also be noted that this fix was generated in concert
with an additional tempest test case, because this overall failure
case needed to be reproduced to ensure we had a workable non-breaking
path forward.
Closes-Bug: 2032377
Change-Id: I9a3b3dbb9ca98771ce2decf893eba7a4c1890eee
* Update ironic-python-agent from branch 'master'
to 768aa174427a28fb0df96bccde70f06f1d831b6f
- Merge "Add mlnx deploy_step entry to enable deploy time firmware"
- Add mlnx deploy_step entry to enable deploy time firmware
Follow-up from service steps addition change to add a deploy steps
alias for the Nvidia Mellanox network device firmware update clean
steps. This allows deploy time firmware updates to be codified as
part of a deployment with custom steps.
Change-Id: I9d80447dee7cfde4d3f8d81d9d39e738916b7824
* Update ironic-python-agent from branch 'master'
to 7a4114512cbbb70dd656d025813df8868e32f30e
- Merge "Handle different device outputs for multipath"
- Handle different device outputs for multipath
In some cases the output of the multipath can differ
and we would return a wrong parent device.
Closes-Bug: 2043992
Change-Id: I848d7df798cc736bd5a55eed8fa46110caea1dc3
* Update ironic-python-agent from branch 'master'
to 9f9940efdcea2c580911b7a69d8f9af80543f08f
- Merge "Test coverage for efi_utils.get_boot_record"
- Test coverage for efi_utils.get_boot_record
A step will be developed to delete all EFI entries of type HD. As part
of this get_boot_record will need to parse more of the output of
`efibootmgr -v`.
This change asserts the existing behaviour of get_boot_record, and the
test can evolve with the changes in get_boot_record.
Related-Bug: #2041901
Change-Id: I0c5ac4adc1044c528c27a4eaf580c619ceef47e0
* Update ironic-python-agent from branch 'master'
to 7a523146950ba2b2f509d41e92d785c77beaaabe
- fix multipathd error handling release notes
This commit:
- fixes some "multipathd error handling improvement"
release notes
- fixes a related comment in the code
Related launchpad issue https://bugs.launchpad.net/ironic-python-agent/+bug/2031092
Change-Id: Ie3ba0601fa117b053cb8db6284e47249ca9c9134
Signed-off-by: Adam Rozman <adam.rozman@est.tech>
* Update ironic-python-agent from branch 'master'
to 845df338f8ce65d9ea9682c6aa7199534c3a2376
- Merge "improve multipathd error handling"
- improve multipathd error handling
This commit:
- Adds the ability to ignore inconsequential OS error caused
by starting the multipathd service when an instance of the
service is already running.
Related launchpad issue https://bugs.launchpad.net/ironic-python-agent/+bug/2031092
Change-Id: Iebf486915bfdc2546451e6b38a450b4c241e43a8
* Update ironic-python-agent from branch 'master'
to 9d9568ba2351a80da6e354154434b1f47bc7ab24
- Merge "Get numa_node info when collecting pci devices info"
- Get numa_node info when collecting pci devices info
IPA now includes information about numa node id when collecting
information about PCI devices.
Closes-bug: #1622940
Co-Authored-By: Jay Faulkner <jay@jvf.cc>
Change-Id: I70b0cb3eff66d67bb8168982acbbf335de0599cd
* Update ironic-python-agent from branch 'master'
to 3d4229861931c42c9ad3bcfde551def6c725214e
- Remove standby.cache_image support
Image caching was never fully supported in Ironic or IPA; this is vestigal
code leftover from a partial implementation.
Even if we implemetented it today, we'd likely use a completely different
methodology.
Change-Id: Id4ab7b3c4f106b209585dbd090cdcb229b1daa73
* Update ironic-python-agent from branch 'master'
to b42f0be4226abba4a8e443c04a037fc6bd934faa
- Merge "implement basic-auth support for user-image download process"
- implement basic-auth support for user-image download process
This feature was proposed in https://bugs.launchpad.net/ironic-python-agent/+bug/2021947
Change-Id: I9dbfc1402240beb75b6736214753fd86dccae676
* Update ironic-python-agent from branch 'master'
to dbf3e5408d3b100505685638a4cbf6c93f9283fe
- Replace shlex module with helper function
Used helper function, `parse_device_tags`
from ironic_lib instead of the
shlex module for their identical
functionality. Updated
mock_execute.side_effect for lsblk
compatibility in utils.execute.
Closes-Bug: #2037572
Change-Id: I6600e054f9644c67ab003f0e0f6c380b5c217223
* Update ironic-python-agent from branch 'master'
to cb61a8d6c052f4401d482ca45b43bc53935a6b28
- Retry on checksum failures
HTTP is a fun protocol.
Size is basically optional. And clients implicitly trust the server
and socket has transferred all the bytes. Which *really* means you
should always checksum.
But... previously we didn't checksum as part of retrying.
So if anything happened with python-requests, or lower level
library code or the system itself causing bytes to be lost off the
buffer, creating an incomplete transfer situation, then we wouldn't
know until the checksum.
So now, we checksum and re-trigger the download if there is a
failure of the checksum.
This involved a minor shift in the download logic, and resulted in
a needful minor fix to an image checksum test as it would loop for
90 seconds as well.
Closes-Bug: 2038934
Change-Id: I543a60555a2621b49dd7b6564bd0654a46db2e9a
* Update ironic-python-agent from branch 'master'
to 89be7bd420da907cff97fad30c6b232ecb1ba76c
- Merge "Conditional creation of RAIDed ESP for UEFI Software RAID"
- Conditional creation of RAIDed ESP for UEFI Software RAID
Rebuilding an instance on a RAIDed ESPs will fail due to sgdisk
running against an non-clean disk and bailing out. Check if there
is a RAIDed ESP already and skip creation if it exists.
Change-Id: I13617ae77515a9d34bc4bb3caf9fae73d5e4e578
* Update ironic-python-agent from branch 'master'
to 25704d25557973e5b76bdc67217c0f6ed2596fc7
- Add additional mock tests to unit tests for read only devices.
Change ordering to ensure mock tests work correctly.
Closes-Bug: #2037690
Change-Id: Ie9b884e58e4677a47e57c3ad39cadd65db8eec75
* Update ironic-python-agent from branch 'master'
to 23c8427224b85cc960cbed17071e8e895401b6fa
- Merge "Extend the lookup timeout to 600 seconds"
- Extend the lookup timeout to 600 seconds
Changes the default lookup timeout to be 600 seconds which
reduces the risk of lookup failing as a write operation
to the backing database is performed upon lookup thanks to
generation of an agent token.
Overall, this is fairly harmless since by default ramdisks
restart the agent if they were not able to successfully
start.
Change-Id: I35c64c0b4f9b3b607df1bc0c4c2a852aa3595cbd
* Update ironic-python-agent from branch 'master'
to db9545eeecd1949e0e9528dcabc735bd7c963caf
- Update master for stable/2023.2
Add file to the reno documentation build to show release notes for
stable/2023.2.
Use pbr instruction to increment the minor version number
automatically so that master versions are higher than the versions on
stable/2023.2.
Sem-Ver: feature
Change-Id: I8150eb8f35a444ef5a2bc7a648ec301e5094e52d
* Update ironic-python-agent from branch 'master'
to 73b76da5fe1b059378407b99ecadb9e30aed2535
- Merge "Add get_service_steps logic to the agent"
- Add get_service_steps logic to the agent
Initial code patches for service steps have merged in
ironic, and it is now time to add support into the
agent which allows service steps to be raised to
the service.
Updates the default hardware manager version to 1.2,
which has *rarely* been incremented due to oversight.
Change-Id: Iabd2c6c551389ec3c24e94b71245b1250345f7a7