Commit graph

579 commits

Author SHA1 Message Date
Brian C. Lane
8cfba81b2c prepare-source: Move go fmt to last step
When rebasing, the generated code ends up with conflict markers in it
and go fmt quits with an error. This change regenerates the code first
so that fmt is happy with it.
2024-08-12 02:43:38 -07:00
Jakub Rusz
1af3bd6e34 tests/libvirt: disable secure boot for el-10
Related bug: CNV-41858
2024-08-12 08:39:05 +03:00
Jakub Rusz
27a8145d66 tests/libvirt: define el-10 variants 2024-08-12 08:39:05 +03:00
Tomáš Hozza
02c35060b9 define-compose-url.sh: support RHEL-10 composes
Signed-off-by: Tomáš Hozza <thozza@redhat.com>
2024-07-23 12:14:13 +02:00
Tomáš Hozza
58e2303143 define-compose-url.sh: use download.devel.redhat.com
Use mirror-agnostic URL for composes.

Signed-off-by: Tomáš Hozza <thozza@redhat.com>
2024-07-23 12:14:13 +02:00
Tomáš Hozza
d0006b0134 define-compose-url.sh: drop RHEL-8 support
There are no more RHEL-8 nightly composes, thus we don't need the code
that defines the repo url for them.

Signed-off-by: Tomáš Hozza <thozza@redhat.com>
2024-07-23 12:14:13 +02:00
Tomáš Hozza
3e8dc4ca8c define-compose-url.sh: drop condition for RHEL-9.1
We are long time past RHEL-9.1 development and this is therefore not
needed any more.

Signed-off-by: Tomáš Hozza <thozza@redhat.com>
2024-07-23 12:14:13 +02:00
Achilleas Koutsou
1cc90c6a0b go.mod: update to go v1.21
Go 1.21 is included in all currently supported distro versions.
It is required by new updates to some of our dependencies, including
osbuild/images.
2024-07-04 19:01:07 +02:00
Florian Schüller
c36367d4cc makefile: implement make lint 2024-07-04 17:52:44 +02:00
Sanne Raymaekers
5347c82dc9 tools/koji-compose: deal with rhsm repositories 2024-07-03 16:52:02 +02:00
Sanne Raymaekers
b8cebc17ae tools/image-info: fix _read_inifile_to_dict
`RawConfigParser.readfp` was deprecated in favour of `.read_file`.
2024-07-01 14:09:08 +02:00
Sanne Raymaekers
a83c794a95 tools/test-case-generators: update rhel8.10 repos
Only the newer snapshots have `rhui-azure-rhel8-base-sap-ha`.
2024-06-28 12:02:24 +02:00
Sanne Raymaekers
ae5f82dc33 tools/test-case-generators: use newer google repo snapshots 2024-06-28 12:02:24 +02:00
Tomáš Hozza
8c54226793 Test manifests: update RH release key and regenerate manifests
Regenerate all manifests.

Signed-off-by: Tomáš Hozza <thozza@redhat.com>
2024-06-12 11:29:56 +02:00
Tomáš Hozza
ab4dd4995c Remove F37 and F38 test manifest, because they are EOL
Signed-off-by: Tomáš Hozza <thozza@redhat.com>
2024-06-12 11:29:56 +02:00
Tomáš Hozza
ff433563c0 Remove c8s test manifest, because it is EOL
Signed-off-by: Tomáš Hozza <thozza@redhat.com>
2024-06-12 11:29:56 +02:00
Alexander Todorov
537fe1a033 Define 9.5 repositories for gen-manifests 2024-06-07 10:31:54 +02:00
Tomáš Hozza
f3e83a3838 Tools/provision.sh: adjust conditional EPEL installation for el10
EPEL-10 can't be installed on any of c10s and el10. Previously, the
script would try to install EPEL repositories package on el10 and fail.

In addition, use our "workaround" repository with c10s builds of some
packages (such as koji) also on el10.

Signed-off-by: Tomáš Hozza <thozza@redhat.com>
2024-06-04 17:17:19 +02:00
Tomáš Hozza
f9079ae39c Tools/provision.sh: add workarounds for c10s
There is no EPEL for RHEL-10 at this moment. Use our own COPR repository
with c10s builds of some packages required by our tests.

Signed-off-by: Tomáš Hozza <thozza@redhat.com>
2024-06-04 13:03:37 +02:00
Sanne Raymaekers
4629a31f22 templates/packer: use python3.10 on fedora
Ansible on fedora 40 seems broken, the default python 3.12 interpreter
doesn't work, 3.10 works but then the dnf module breaks.

Use 3.10 and stop using the dnf module.
2024-05-31 13:55:58 +02:00
Tomáš Hozza
71b9c0ad65 Fix pylint issues
Add timeout to `requests.post()` and `requests.get()` calls to make
pylint happy.

Signed-off-by: Tomáš Hozza <thozza@redhat.com>
2024-05-30 19:58:34 +02:00
Sanne Raymaekers
a96f1b6d31 templates/packer: switch to fedora-40
Fedora 38 is EOL, and packit no longer builds rpms for it.

The current python3.12 + ansible 2.12 combination which is the default
on fedora 40 doesn't work, so switch to python3.9.
2024-05-29 19:36:31 +02:00
Achilleas Koutsou
4241f5bb39 tools/gen-ssh: upgrade openssh before generating key
openssl gets installed as a dependency of the osbuild-composer-tests but
it might not update openssh at the same time, which can cause a version
mismatch when running ssh-keygen:

  OpenSSL version mismatch. Built against 30000000, you have 30200010

This is currently happening in CentOS Stream 9 so let's make sure
openssh is up to date before running ssh-keygen.
2024-05-29 00:27:31 +02:00
Sanne Raymaekers
13aae7d532 templates/packer: invert tag logic
With the rpmcopy or rpmrepo_osbuild tags, the `Install worker rpm` stage
got skipped on RHEL and CI. Invert the tag logic and use `--tags`
instead of `--skip-tags`.
2024-05-21 09:40:11 +02:00
Sanne Raymaekers
9c047cd8e0 tools/fedora-worker-packer: don't trace statements
It makes the logs extremely verbose, and requests/responses are already
printed when relevant.
2024-05-07 18:38:13 +02:00
Sanne Raymaekers
aadf5dfc9a tools/fedora-worker-packer: increase timeouts further
The first timeout increase didn't take effect. And once the suite is
present the rpm builds can stay pending for a very long time.
2024-05-07 18:38:13 +02:00
Sanne Raymaekers
c9ce5af655 tools/fedora-worker-packer: set the commit sha
Currently the COMMIT_SHA variable is empty.
2024-05-07 14:47:59 +02:00
Sanne Raymaekers
28e4b0aa07 tools/fedora-worker-packer: increase timeout waiting for packit 2024-05-07 14:47:59 +02:00
Sanne Raymaekers
a1476bdfb1 tools/appsre-build-worker-packer: stop writing bogus files 2024-05-07 13:57:48 +02:00
Sanne Raymaekers
61848cb88d tools/appsre-build-fedora-worker-packer: wait for packit
Wait for packit to complete it's runs, after which the rpms should be
available from the @osbuild/osbuild-composer copr repo.
2024-05-07 13:57:48 +02:00
Sanne Raymaekers
616db61105 tools/build-worker-packer: skip rpmcopr for RHEL and on CI
Also skip both rpmrepo tasks on RHEL.
2024-05-07 13:57:48 +02:00
Achilleas Koutsou
f98169c29a go.mod: update to go v1.20
Go 1.20 is included in all currently supported distro versions.

Signed-off-by: Achilleas Koutsou <achilleas@koutsou.net>
2024-04-11 16:39:21 +02:00
Alexander Todorov
4db594dac7 Skip image_installer tests b/c already tested in installers.sh 2024-03-06 09:09:39 +01:00
Alexander Todorov
d7388fdc66 Remove already tested manifests from test-case-generators
and remove redundant skips from image_tests.sh
2024-03-06 09:09:39 +01:00
Tom Koscielniak
b4dcfc4480 Remove libvirt workaround 2024-03-04 15:39:08 +01:00
Sanne Raymaekers
c138ea6939 tools/appsre-build-fedora: wait until rpms are built upstream
The fedora build script should wait until the rpms are released upstream
before starting the build, otherwise the rpms will come from the fedora
repos.
2024-02-22 16:05:46 +01:00
Xiaofeng Wang
fc81b89cde test: remove workarounds for fixed bugs
Bugs have been fixed, workarounds are not needed anymore.
2024-02-07 08:52:30 +01:00
Tomáš Hozza
0c0a758600 Packer: default to RHEL-9.3 Schutzfile config for rhel-9
This is necessary to get the proper osbuild SHA to install the latest
required osbuild version into the image.

Signed-off-by: Tomáš Hozza <thozza@redhat.com>
2024-01-26 11:32:34 +01:00
Tomáš Hozza
2fe5e01d4d Test/api.sh: test distro aliases and names without dot-notation
Extend the `api.sh` to allow testing compose requests with distro name
which does not use dot-notation (specifically when the dot is removed
from the distro name as it used to be in the past). In addition to that,
allow also testing the distro alias using distro name without the minor
version in compose requests.

Enable these two new test variants in the CI.

Signed-off-by: Tomáš Hozza <thozza@redhat.com>
2024-01-26 11:32:34 +01:00
Tomáš Hozza
66571784d1 Use dot-notation for repo configs and in test cases.
Where applicable, modify all repo config filenames to use a dot
to separate the release major and minor version. Modify test cases
to not remove dot from the distro version any more.

Existing tests will be extended (or new tests added) to explicitly test
backward compatibility and ensure that using old distro names without a
dot still works.

Signed-off-by: Tomáš Hozza <thozza@redhat.com>
2024-01-26 11:32:34 +01:00
Tomáš Hozza
79d5ab483b tools: delete old Python manifest generator scripts
These are no longer used, let's delete them.

Signed-off-by: Tomáš Hozza <thozza@redhat.com>
2024-01-26 11:32:34 +01:00
Sanne Raymaekers
589bd5f1a1 tools/fedora-worker-packer: fix packer only/except
It should only build fedora, not everything except fedora.
2024-01-23 13:06:38 +01:00
Sanne Raymaekers
6a0c893a4d tools/appsre-packer: add script to build fedora worker images 2024-01-23 00:18:51 +01:00
Sanne Raymaekers
c7aad1b17d tools/app-sre-build-worker-packer: split out the CI script
To add the fedora workers built from AppSRE's infrastructure, we need a
combination that wasn't possible with the current matrix based on the CI
environment (jenkins vs gitlab).
2024-01-23 00:18:51 +01:00
Sanne Raymaekers
3631316e36 tools/build-rpms: fix getting the osbuild commit from Schutzfile
osbuild/osbuild-composer#3614 removed the rhel-8.6, the centos-stream-9
entry should be there for a while at least.
2024-01-16 16:26:01 +01:00
Brian C. Lane
978c20d36f tools: Add helper script to check Schutzfile and gitlab-ci.yml runners
This script reads the RUNNER entries from .gitlab-ci.yml and the
snapshot repo names from Schutzfile. It then prints which runners don't
have entries in Schutzfile and which Schutzfile entries don't have
runners.

This is slightly complicated by the fact that centos-stream reports
itself as centos. So when checking for missing entries they are
considered to be the same thing. eg. If centos is a RUNNER and
centos-stream is in Schutzfile it doesn't report anything missing.
2024-01-16 12:29:21 +01:00
Michael Vogt
973a8cf285 image-info: update for new "partition" option in mounts.Mount
In the osbuild PR#1501 [0] a new paramter "partition" for
mounts.Mount() was added.

This commit updates the code that it deals cleanly with the new
and the old API for `mount.Mount`.

[0] https://github.com/osbuild/osbuild/pull/1501
2024-01-10 09:38:31 +01:00
Ondřej Budai
7bcf8e5942 test-case-generators/repos: add required repos for azure-sap-rhui
This image requires a different RHUI repository and also the saphana one.

Similarly to the previous commit, we should probably remove the manifest diff
tests altogether, but let's just fix them for now.

Signed-off-by: Ondřej Budai <ondrej@budai.cz>
2023-12-22 00:11:19 +00:00
Miguel Martín
991293a897 Generate FIPS compliant SSH keys
Generate FIPS compliant SSH keys required
for testing system FIPS mode support
2023-12-13 10:19:47 +01:00
Sanne Raymaekers
4ee00f7dab tools/provision: disable tracing before manipulating OCI secrets 2023-11-07 10:43:32 +01:00