* Update ironic-lib from branch 'master'
to 42fa5d63861ba0f04b9a4f67212173d7013a1332
- 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: I14a93e67735df0f1b82dd687873ec77d8bfaac78
* Update ironic-lib from branch 'master'
to ac32c33b6886bf5efd4fba72905b7fddc629b5b5
- Merge "Remove compatibility with Python < 3.8"
- Remove compatibility with Python < 3.8
... because this library now supports only Python 3.8 or newer
versions.
Change-Id: Ice1bec17f23ab1fa7abdafa324e0b83942b4101a
* Update ironic-lib from branch 'master'
to ae53e8e4b386992ed2c6cfc1648f3b2f3062e156
- Swap partprobe and udev settle
On ubuntu based systems calling these in opposite causes a
race condition where partitions aren't ready when we read/use them
Closes-Bug: 2050013
Change-Id: Ied7e4f17786dfc0e7f54962013e48ff96c5faa88
* Update ironic-lib from branch 'master'
to 118da00f2f864dffb62374dbb1772d1332d54bd4
- Merge "Split common qemu-img functions from disk_utils"
- Split common qemu-img functions from disk_utils
Adds a new module for two qemu-img wrappers that are used both by Ironic
and IPA. The remaining functions in disk_utils are only used by IPA and,
since most of them require root, can no longer be used in the
post-rootwrap Ironic any more. They should be moved to IPA eventually.
Change-Id: I3364a58b52a3e57c2f52356a6496865b749e74a8
* Update ironic-lib from branch 'master'
to 64d82cd1d6c836dad0b2f3e824b534fdbe0bfd8e
- Merge "Bump hacking to 6.1.0"
- Bump hacking to 6.1.0
... which is the latest version available now.
Change-Id: I777ae1dd4202ae43da35089a36fc760894acae6e
* Update ironic-lib from branch 'master'
to 87a739fe178c241d640238c9d162036c02ab2a31
- Raise on non-existing file in qemu_img_info
I'm not sure why we silence the exception, right now it causes us a very
hard to debug failure. No code in Ironic seems to rely on this behavior.
Change-Id: I3740b600c60ed1b39808d18af2b5074e7e07a149
* Update ironic-lib from branch 'master'
to 5e1ca2a43724f3d3737c6388656d17caa815a8e2
- [codespell] Add tox target and configuration for codespell
Continuing the work of @JayF in other repos.
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: https://bugs.launchpad.net/ironic-python-agent/+bug/2047654
Change-Id: I284045ee9dfb51eee59a0442abda657c74abed05
* Update ironic-lib from branch 'master'
to 7952b5d7887894583411cf1504bfac29470d42dd
- [codespell] Fixing spelling issues in Ironic-Lib
Continuing work by @JayF in other ironic repos. Find that explanation below.
This fixes several spelling issues identified by codepsell.
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: https://bugs.launchpad.net/ironic-python-agent/+bug/2047654
Change-Id: I38ad9c46add87b0e67c912f2920f76ea7d0c3b80
* Update ironic-lib from branch 'master'
to 536db45764c7ef5a0d9d0d0a75aa5e490c834dd4
- Merge "Drop lower-constraints.txt (again)"
- Drop lower-constraints.txt (again)
The commit 9d116cd7c68906f386f5b14e98af4bb12d2458a8 says it removes
the file but it didn't.
Change-Id: I1a519b205cce0fc7eeefba8f162d4542c4412425
* Update ironic-lib from branch 'master'
to 523407eebf22b68a3b1a3926666e8bb24fedf871
- Merge "Compatibility with zeroconf 0.129.0"
- Compatibility with zeroconf 0.129.0
From Zeroconf CHANGELOG.md:
v0.129.0 (2023-12-13)
Feature
* Add decoded_properties method to ServiceInfo
https://github.com/python-zeroconf/python-zeroconf/issues/13329b595a1dca
* Ensure ServiceInfo.properties always returns bytes
https://github.com/python-zeroconf/python-zeroconf/issues/1333d29553ab7d
Technically breaking change
* `ServiceInfo.properties` always returns a dictionary with type
`dict[bytes, bytes | None]` instead of a mix `str` and `bytes`. It was
only possible to get a mixed dictionary if it was manually passed in
when `ServiceInfo` was constructed.
Co-Authored-By: Dmitry Tantsur <dtantsur@protonmail.com>
Change-Id: I7f1a0c3329e5f29ec3e274558e3681142cc2ef78
* Update ironic-lib from branch 'master'
to 078cdabdf58108a253b457647e9b0307bd0ca1ce
- Improve error message for wrong metrics backend
We should breadcrumb the operator into what this message means -- right
now, it looks like a programming error when in most cases this is a
configuration error.
Related-bug: 2047709
Change-Id: Ica627834f799cffbf283ee01a2b2482a607c316d
* Update ironic-lib from branch 'master'
to 54597e9210b5407711b0e4fa047ce9b6b7247116
- Merge "Trivial: remove an incorrect comment"
- Trivial: remove an incorrect comment
IP addresses work, we even have unit tests for them.
Change-Id: I2765047896d722e647e69f0a03e3bb3b48c41b3b
* Update ironic-lib from branch 'master'
to a0e26d4f8e848b8291968af04612d7207b6eacf8
- Merge "JSON RPC: add support for unix sockets and extract common code"
- JSON RPC: add support for unix sockets and extract common code
Listening on Unix sockets is helpful when the whole Ironic is behind
a reverse proxy, as it's the case in Bifrost and Metal3 with TLS on.
This change also extracts some common code to be reused in Ironic later.
Change-Id: I3488b9bb67470ce6d062187dc5e44852f6908493
* Update ironic-lib from branch 'master'
to 2f7f72e14710219128e11e84b95a4ef81bee511e
- Increase the ESP partition size to 550 MB
This change makes ironic-lib consistent with ironic-python-agent
and diskimage-builder's defaults for ESP partition sizes.
The following fedora change lays out why this is a necessary
change: https://fedoraproject.org/wiki/Changes/BiggerESP
In summary, additional space is needed if OS driven firmware
flashing is going to take place, and unikernels + next generation
bootloaders are going to consume more space than the existing
grub loader has.
Change-Id: I4fc63c02bf57a08e75121cfa1fd35a56c0427553
* Update ironic-lib from branch 'master'
to bdbd0e9287610341c7e570769b0ec6541019bde2
- Merge "Add jsonrpc client port capability"
- Add jsonrpc client port capability
Adds the capability for the topic to contain a port to which
the json rpc client will connect to. This allows for distinct
json-rpc targets to be configured in an environment.
Change-Id: I999316880639cd410543eb54475b0c647b35147b
* Update ironic-lib from branch 'master'
to 853bedce5cd87c72e457cc7f551bdfd02aae3113
- Upgrade to latest hacking - v6
Includes a single minor change to comply with latest flake8.
Change-Id: Ifda4810940f5c4d963946939f103f65175cc7868
* Update ironic-lib from branch 'master'
to 7a00c0d6745697db0d98840c96568abaa08ec6db
- Exclude all files starting with . from flake8 tests
Some tests tool and IDE may create a .local directory inside the repo
with virtualenvs for dependencies, other tools may create . directories
or files for temporary reports.
While they can be removed in a second time, or configured differently,
it's advisable to just exclude all file starting with . from the
flake8 tests to avoid confusion and possible unexpected errors.
Change-Id: Iea00e194fbe9c89754fb0a65cdaaabdaad31e4cc
* Update ironic-lib from branch 'master'
to ec6ba65392d189fc3e7a371aa356d3de5d66012b
- Use direct writes when erasing the GPT
Use direct I/O when overwriting the partition table to expose device
failures (which would not be directly noticed otherwise).
Change-Id: Ib0790099d895410681e4a1679bedea62209ff277
* Update ironic-lib from branch 'master'
to 71a765572302176caced8c0b934dc3c13c726673
- Merge "Provide an interface to store metrics"
- Provide an interface to store metrics
Internally, if we want to re-use ironic-prometheus-exporter
*and* get useful metrics data out through it for ironic itself,
we need we need someway to collect and return metrics data.
Turns out, we did most of this for statsd ages ago, and we can
just reuse the framework.
Change-Id: I6060da4ab80c2e6d19d78b808216ae262edcc84c
* Update ironic-lib from branch 'master'
to 55b67de89ef048e1440cf95c4a4da94ba1d4fd4d
- Fix tox4 error
Remove skipsdist that it was never supported and causes breakage
when used with usedevelop.
Change-Id: I20029ec4944b68a98c1b94b2b76dd81dcd2c5209
* Update ironic-lib from branch 'master'
to 1c6af2e63a31282f939ce0e4ab684ee0013e546d
- No longer override install_command in tox.ini
Per ClarkB on the list, overriding install_command makes it more
difficult to troubleshoot behavior differences and failures.
Change-Id: I3fb6760bf4754bd1688db173037e55c238a0601e
* Update ironic-lib from branch 'master'
to c0ae15fb9ccb5075632bd41a3f0e50ee055e0c47
- Add Python3 antelope unit tests
This is an automatically generated patch to ensure unit testing
is in place for all the of the tested runtimes for antelope.
See also the PTI in governance [1].
[1]: https://governance.openstack.org/tc/reference/project-testing-interface.html
Change-Id: If9bde0075d92c09491085d1c6dc05e36d0810fe1
* Update ironic-lib from branch 'master'
to ded2a504e20b084f06e3d6b11c8c1700b1e740a5
- Merge "Drop lower-constraints.txt and its testing"
- Drop lower-constraints.txt and its testing
As discussed in TC PTG[1] and TC resolution[2], we are
dropping the lower-constraints.txt file and its testing.
We will keep lower bounds in the requirements.txt file but
with a note that these are not tested lower bounds and we
try our best to keep them updated.
[1] https://etherpad.opendev.org/p/tc-zed-ptg#L326
[2] https://governance.openstack.org/tc/resolutions/20220414-drop-lower-constraints.html#proposal
Change-Id: I0f09e027650d5c2953dab7191b3f3286a37057f1
* Update ironic-lib from branch 'master'
to 2b8bd311cc0ea1cd007fae3cde4fa5aadf996ca8
- Merge "Replace the netboot job with a local-boot one"
- Replace the netboot job with a local-boot one
Change-Id: I14b4134f6ba3f3d04d89a19caec3dc253a1d537f
* Update ironic-lib from branch 'master'
to 2337a065335cfb91d75d502a69e227e0e28bbe03
- json_rpc.client: log the URL and exceptions
Change-Id: I0c02d68fd82dc5c9d5fec32ca98f02e98228eca2
* Update ironic-lib from branch 'master'
to 0aa35a0edba4cce619d35c9964e975eadb79f9f8
- Remove python version 2 pkgs from bindep
Follow up to change: Iee5ac3a778f8106b7f2e96cd9294e2da28fe4def
Since Python version 2 is not supported we can remove these.
Change-Id: I79a4b189a7fb220a97d83601002339ebfae45104
* Update ironic-lib from branch 'master'
to 5662b92fda78e123dd3adfcc2c818ff251af6ec1
- Use TOX_CONSTRAINTS_FILE
UPPER_CONSTRAINTS_FILE is old name and deprecated
This allows to use upper-constraints file as more
readable way instead of UPPER_CONSTRAINTS_FILE=<lower-constraints file>.
Change-Id: I7b79d0bc10c4c5c48e167e7042d383921feb1486
* Update ironic-lib from branch 'master'
to d67fa037cd03a4b6f4c7dead6677b83343ba5a4b
- Merge "Add Python3 zed unit tests"
- Add Python3 zed unit tests
This is an automatically generated patch to ensure unit testing
is in place for all the of the tested runtimes for zed.
See also the PTI in governance [1].
[1]: https://governance.openstack.org/tc/reference/project-testing-interface.html
Change-Id: Id611d09e96e43a19c145db61fa717151b4a20bdd
* Update ironic-lib from branch 'master'
to 95ce746ad101b7af32684c29384237061565a4af
- Update jobs names
Also actually set netboot to bios
Change-Id: I572d723e6b0d685a8a1ce9ec21c86adce3f25db4
* Update ironic-lib from branch 'master'
to 7d68f9484c09ceb322379b4f20446259f53fe92b
- Follow-up Allow customizing roles to use JSON RPC
This is a follow-up for I143203be7827f73daba32e7c084c5807063ff91d
with minor fixes requested in the review.
Change-Id: I83a506b0a489efe56b4a11a954a76fe0783fa4ba
* Update ironic-lib from branch 'master'
to 4ea8df8e21ff8a30b92ed68b3a95d7297736ee2c
- Allow customizing roles to use JSON RPC
This change allows customizing the roles required for JSON RPC, to use
any roles different from the 'admin' role.
There is a plan, as part of SRBAC effort, to replace usage of the admin
role in each service by the new service role, which has more restricted
access, and we expect the ironic service user would require only
the service role once this work is done.
Change-Id: I143203be7827f73daba32e7c084c5807063ff91d
* Update ironic-lib from branch 'master'
to 38f00d1d7d96212635876ab9912a0950d9bc7eda
- Re-add python 3.6/3.7 in classifier
We have updated the yoga testing runtime to keep the
py36 testing.
- https://review.opendev.org/c/openstack/governance/+/820195
Unit tests job template is also updated to keep python
3.6 as a voting job. So with the py3.6 and py3.9 testing as voting
job template, we are keeping python 3.6, 3.7, 3.8, and 3.8 as
tested versions in the Yoga cycle.
- https://review.opendev.org/c/openstack/openstack-zuul-jobs/+/820286
This commit re-add the python 3.6/3.7 versions in setup.cfg classifier.
Change-Id: I7129bb68320a7d6de40feea571e2ac03d4b09166
* Update ironic-lib from branch 'master'
to 51e4d204bee16fccb6ce57cdb57549dc83c79637
- Updating yoga tested python versions in classifier
Yoga testing runtime has been updated with py38 and py39
as voting and removed the py36 testing. Unit tests update are
handled by the job template change in openstack-zuul-job and you
can see the updated jobs running in gate.
- https://review.opendev.org/c/openstack/openstack-zuul-jobs/+/818609
this commit updates the tested py versions in setup.cfg classifier.
[1] https://governance.openstack.org/tc/reference/runtimes/yoga.html
Change-Id: I7cfd594a76c30bb4b603b212aa9e4aca82f4336f
* Update ironic-lib from branch 'master'
to 731e2f9c824ed8bf4a640e66928d5cea3ed167e0
- Restore blkid compatibility with Centos 7
The blkid version included in util-linux 2.23.2 does not allow long
options name for probe and match-tag.
Use the short single letter name to restore compatibility with Centos 7
Story: 2009328
Task: 43764
Change-Id: I10a52c16ebe4e519d0af63b36c3a89fd5d371319
* Update ironic-lib from branch 'master'
to 6260807d515bcfdb7de1009d55463af412324fe2
- Merge "Allow qemu-img to write out zeros to disk"
- Allow qemu-img to write out zeros to disk
Allow the sparse_size for qemu-img to be specified in order
instruct it to write out all zeros(when set to 0). Doing this
will cause it not to zero out the entire block device
which can be very costly on a slow HDD.
Story: 2009227
Task: 43315
Change-Id: I480352be378020a6063fe247238b18713031f6b0
* Update ironic-lib from branch 'master'
to 15f5264394beac31d5bfb1c7711772e2e283e20d
- Add Python3 yoga unit tests
This is an automatically generated patch to ensure unit testing
is in place for all the of the tested runtimes for yoga.
See also the PTI in governance [1].
[1]: https://governance.openstack.org/tc/reference/project-testing-interface.html
Change-Id: I294706753dc791f70833759b6c7cdcd2eb7caa2e
* Update ironic-lib from branch 'master'
to 509d9ce3609091913e1007eea3bcf8bbc8e64dc5
- Merge "Avoid using blkid in favour of lsblk and parted"
- Avoid using blkid in favour of lsblk and parted
Per blkid man page, we should rather use lsblk, which has much better
debugging output (blkid essentially only returns an exit code). Since
the partition table type is not available in lsblk, copy the procedure
using parted from ironic-python-agent.
Change-Id: I3b20754727de904dbe72f358a21f31f00a5fbb77
* Update ironic-lib from branch 'master'
to ac958880594786dd14de6fb22e05f4899b91f1fd
- Drop an explicit requirement of oslo.log
This library is designed for leaf applications (services, CLI). For
libraries it's enough to use the generic logging.
Unit tests needed adjustment since LOG.exception is implemented via
LOG.error internally.
Change-Id: I943e1f07a23e76354966acae5e4594e41dd4822b
* Update ironic-lib from branch 'master'
to 44131be92a4a482906ca412ccb3a874b4c5adef0
- Merge "json_rpc: setup.cfg is missing entrypoint for json_rpc's list_opts"
- json_rpc: setup.cfg is missing entrypoint for json_rpc's list_opts
oslo.config is relying on the list_opts entrypoint to automatically
integrate the json_rpc options.
Story: 2009126
Task: 43038
Change-Id: Id50af71faec84bd778422ed86a3b99797158afdb
* Update ironic-lib from branch 'master'
to 1340a735e9150bf784d5a69be253feb18035e440
- Merge "json_rpc: list_opts() should return tuple"
- json_rpc: list_opts() should return tuple
list_opts() should return a tuple otherwise
oslo-config-(genera|valida)tors are unable to parse its output.
Story: 2009126
Task: 43039
Change-Id: Ib4b9c270709f5994bc2c031c339822d7d6b9356d
* Update ironic-lib from branch 'master'
to 4c6a6fba0867966883582354ca30b1cfbfea9014
- Merge "Increase version of hacking and pycodestyle"
- Increase version of hacking and pycodestyle
Change-Id: Ib4340aacba21cadef655998b1729dc6b18e173a8
* Update ironic-lib from branch 'master'
to b750b74c20c71513df089ad6d9ba96f0ec8a7a83
- Add lower-constraints job to current development branch
The lower-constraints test was removed because of an issue where pip
could not correctly determine the required packages versions to install,
ending in an almost infinite loop that would end up in timeout, failure,
and general mayhem.
Recently the issue has been fixed and, if properly configured, the
lower-constraints test can provide good indication of which minimum
versions are required to support the current code.
This patch adds the test back to the current development branch, and it
runs only on master.
The lower-constraints file will stay in the future stable branches.
Fix olso.utils min requirement and remove doc8 from test-requirements
as it's already included in tox.ini config.
Change-Id: Ic0174f59b95a878539ab17f659f1663548e94ed7
* Update ironic-lib from branch 'master'
to d33cf3e0332da7be400fc769eb6f51b6d4e84575
- Use the json format output of qemu-img info
Support for the human format by oslo_utils.imageutils.QemuImgInfo was
deprecated since oslo.utils 4.9.1 [1]. This change replaces the human
format with the json format which will be used by default.
[1] 73eb0673f627aad382e08a816191b637af436465
Change-Id: I4c9bdbccb9345e2259ddb0737f37c09d99dd1c4f
* Update ironic-lib from branch 'master'
to f7db05cc9d60d469377550459ae65f99f3506aaa
- Update min version of tox to use allowlist
The min version of tox is updated to 3.18.0 to replace whitelist_externals
with allowist_externals option [1]
[1] https://github.com/tox-dev/tox/blob/master/docs/changelog.rst#v3180-2020-07-23
Change-Id: I655917f1c44b68118ce22fcf479f3f317636ac98
* Update ironic-lib from branch 'master'
to 831b5c146c8bffa7426c499ff50cd0b046100309
- Merge "Remove the logic specific to the way deployment works"
- Remove the logic specific to the way deployment works
This code used to be shared between the iSCSI and the direct deploy
interfaces. Now that iSCSI is gone, this code has been moved to IPA:
24951b1029
Change-Id: Ia879595d00501f3f06ae5dc2a9dca9c5ea234501
* Update ironic-lib from branch 'master'
to e4d7c1f41e476eb55b84221076fb18c13ebb2071
- utils.execute: log stdout and stderr even on failure
Add logging when a command is not found.
Also remove duplicate logging of exit code and command line:
it's already done by processutils.
Change-Id: I0349073cf0f78fb021dcd3e830fedddf2b4a0c92