Commit graph

530 commits

Author SHA1 Message Date
Juan Abia
4c4e26d996 test/cases: use the same naming pattern on every test
make api.sh and was.sh use the same naming pattern, TEST_ID.
2021-11-11 15:42:32 +01:00
Xiaofeng Wang
ab3712fd92 test: Update ostree test scripts to support different ostree refs 2021-11-11 12:11:01 +01:00
Achilleas Koutsou
89f0613f3d test/cases: rm ostree-ng-og.sh
Obsolete test script
2021-11-10 14:54:31 +01:00
Achilleas Koutsou
e02911bc45 test/data: update manifests for edge-container images 2021-11-10 14:54:31 +01:00
Achilleas Koutsou
2cd3c71370 test/data: update RHEL 9.0 and beta manifests
Distro name is now `rhel-90` (was `rhel-90-ga`)
Beta distro name is `rhel-90-beta` (was `rhel-90`)
2021-11-10 14:54:31 +01:00
Achilleas Koutsou
90219720d4 test/ostree-simplified: variable string fixes
- All variants use the same image type names
- OSTREE_REF differs for each case
- Use OS_VARIANT in virt-install command
2021-11-10 14:54:31 +01:00
Achilleas Koutsou
affe02ceed test/api: ssh key fixes for RHEL 9.0
RHEL 9.0 AWS API test is failing with

  Host key verification failed.

This is probably due to a recent change in openssh deprecating rsa host
keys (or likely rsa keys in general).
- turn off StrictHostKeyChecking when checking groups
- use 'ed25519' type for user ssh keys

Signed-off-by: Achilleas Koutsou <achilleas@koutsou.net>
2021-11-10 14:54:31 +01:00
Achilleas Koutsou
8ef0cfe618 test/cases: support weldr-client output structure
Using get_build_info() function in all scripts where both composer-cli
and weldr-client need to be supported for consistency.
2021-11-10 14:54:31 +01:00
Achilleas Koutsou
2f30823b41 test/ostree: install python3 instead of specific version
Better cross-distro compatibility

Same as bdc428fbb7 but for all the tests.

Signed-off-by: Achilleas Koutsou <achilleas@koutsou.net>
2021-11-10 14:54:31 +01:00
Achilleas Koutsou
a025601b85 test/cases: add RHEL 9.0 and CentOS 9 cases to test scripts 2021-11-10 14:54:31 +01:00
Achilleas Koutsou
7e9f1f554e test: update test manifests for rhel-90-ga
Changes from previous (RHEL 9.0 Beta):
- Edge container: Switched to nginx from apache. Change in pipeline and
  package sets.
- All bootable x86_64: Packages for hybrid boot added (efibootmgr).
- Edge commit and edge container no longer require explicitly enabling
  greenboot services.
2021-11-10 14:54:31 +01:00
Achilleas Koutsou
c8465e3161 test/data: copy rhel-90 test manifests to -ga and -beta
All three "distros" share the same code for now. Adding manifests to
track changes before updating the RHEL 9.0 GA definitions.

Signed-off-by: Achilleas Koutsou <achilleas@koutsou.net>
2021-11-10 14:54:31 +01:00
Achilleas Koutsou
bbf825ef12 test: add repositories for rhel-90-beta and -ga
- Updated repos to use latest nightly (20211105)
- Added rt repository
- Both -ga and -beta are identical
- rhel-90.json repo file is a symlink to rhel-90-beta.json

Signed-off-by: Achilleas Koutsou <achilleas@koutsou.net>
2021-11-10 14:54:31 +01:00
Tom Gundersen
f44acd0974 Revert "Revert "cloudapi/v1: Move depsolving to workers""
Workers now depsolve in parallel to image builds, so we can
again move depsolivng to the workers. This will help us deal
with increases in traffic as we currently only have one
depsolve handler per pod. It would also avoid any issues with
composer running out of disk space due to dnf metadata caches.

This reverts commit c65b1e9b26.
2021-10-26 13:58:22 +01:00
Ondřej Budai
83a35fb9b8 ci: remove 8.5 nightly testing
It no longer makes sense because:

- we don't make any changes to 8.5
- we don't regenerate test manifests for 8.5
- osbuild-composer for 8.5 is in the rhel-8.5.0 branch

Also, the latest-8.5.0 symlink was removed, which broke the CI.

Signed-off-by: Ondřej Budai <ondrej@budai.cz>
2021-10-26 09:30:21 +01:00
Achilleas Koutsou
aea77ed3de test: timestamp messages in test scripts
The commonly used 'greenprint' function now adds a date + timestamp to
each message for debugging and tracking the duration of segments of each
scripts.
2021-10-24 16:13:53 +01:00
Achilleas Koutsou
62a9aadfe4 test/api: SSH_USER=ec2-user for centos on AWS 2021-10-21 15:16:04 +01:00
Achilleas Koutsou
63fd590fc2 test/cases: add centos-8 as support to test scripts
Add centos-8 as a supported distro in ostree test scripts.

Signed-off-by: Achilleas Koutsou <achilleas@koutsou.net>
2021-10-21 15:16:04 +01:00
Achilleas Koutsou
a180c06fc4 test/ansible: install greenboot-failing-unit from public source
Use --cache-only to skip trying to update the cache.

Signed-off-by: Achilleas Koutsou <achilleas@koutsou.net>
2021-10-21 15:16:04 +01:00
Achilleas Koutsou
0cb95ee9b6 test/data: regenerate manifests for CentOS 8
Signed-off-by: Achilleas Koutsou <achilleas@koutsou.net>
2021-10-21 15:16:04 +01:00
Achilleas Koutsou
c7df2f1bc7 test/data/repositories: update cs8 rpmrepo snapshot
Signed-off-by: Achilleas Koutsou <achilleas@koutsou.net>
2021-10-21 15:16:04 +01:00
Achilleas Koutsou
e4f42066bb test: add RHEL 8.6 image installer test manifest
Installer test manifests don't contain image info but are useful for
detecting changes to the manifest.

Signed-off-by: Achilleas Koutsou <achilleas@koutsou.net>
2021-10-21 15:16:04 +01:00
Ondřej Budai
ece191f73e ostree: change the URL for OC client temporarily
mirror.openshift.com is temporarily down.

Revert this commit when the server is working as usual.

Signed-off-by: Ondřej Budai <ondrej@budai.cz>
2021-10-21 07:28:46 +02:00
Ondřej Budai
b606e8afca test/aws: remove a no longer needed key from an instance
It's actually not needed, remove it.

Signed-off-by: Ondřej Budai <ondrej@budai.cz>
2021-10-21 07:28:46 +02:00
Ondřej Budai
58423c262b ci: rotate secret names
Signed-off-by: Ondřej Budai <ondrej@budai.cz>
2021-10-21 07:28:46 +02:00
sanne
87cc722021 cloudapi/v2: Plural path section when querying a collection 2021-10-14 16:22:24 +02:00
Thomas Lavocat
010a1f5022 worker: Configure AWS credentials in the worker 2021-10-14 02:10:54 +01:00
Sanne Raymaekers
c65b1e9b26 Revert "cloudapi/v1: Move depsolving to workers"
This reverts commit 0f44250237.
2021-10-13 12:01:51 +02:00
sanne
cb5acbac74 worker: Prefix https always
Also, with oauth, add a root CA if present.
2021-10-12 17:59:59 +01:00
sanne
0f44250237 cloudapi/v1: Move depsolving to workers
We can't enqueue a job without a worker doing the depsolve step now, so
adapt the tests as well.
2021-10-12 14:21:03 +01:00
sanne
6ce20a9ef6 cloudapi/v2: Listen on /api/image-builder-composer/v2 2021-10-11 09:52:21 +02:00
Achilleas Koutsou
01d920ac01 test/ostree: remove --ip-range from podman network
Bug in podman causes the command to fail with this flag. Not really
needed.
2021-10-11 09:49:15 +02:00
Tomas Hozza
eac6b2c083 RHEL-8.6: add support for official EC2 SAP image
Add support for building the official RHEL EC2 SAP image for RHEL-8.6.
The new image type is available under the `ec2-sap` name. Since the
image type's package set includes RHUI client RPMs, which are not
available publicly, it is by default not exposed through the Weldr API.

Extend the relevant files and definitions used for generating image test
cases. This includes addition of repository definitions needed by the
image type, specifically: `sap`, `saphana` and `ansible`.

Generate image test case for the new image type.

Add News entry for the new image type.

Signed-off-by: Tomas Hozza <thozza@redhat.com>
2021-10-11 09:49:15 +02:00
Achilleas Koutsou
be16a6e502 test/cases: add support for RHEL 8.6 to test scripts
Signed-off-by: Achilleas Koutsou <achilleas@koutsou.net>
2021-10-11 09:49:15 +02:00
Achilleas Koutsou
1cff6c7dd2 test: add RHEL 8.6 test manifests
Add images to distro-arch-imagetype map and generate all test cases.
2021-10-11 09:49:15 +02:00
Achilleas Koutsou
0a818641a9 test/data/repositories: add test repos for rhel-86 2021-10-11 09:49:15 +02:00
Tomas Hozza
510bd1d221 Tests/RHEL-9.0: add EC2 SAP image test
Because the RHUI client RPMs for RHEL-9 don't exist yet, this test
case uses the RHUI client RPMs for RHEL-8 to satisfy the required
package set. These RPMs contain the entitlement certificate and repo
definitions for RHEL-8 AWS RHUI repos, but RHUI will not work without
the image being imported with the proper Billing Code to AWS. So these
installed RHUI RPMs are technically useless on the RHEL-9 image, but
this approach is good enough to allow us to at least build and test
the image from configuration point of view.

Signed-off-by: Tomas Hozza <thozza@redhat.com>
2021-10-08 16:34:55 +01:00
Tomas Hozza
7c6c67ef98 Tests/RHEL-9.0: add EC2 and EC2 HA image tests
Because the RHUI client RPMs for RHEL-9 don't exist yet, these test
cases use the RHUI client RPMs for RHEL-8 to satisfy the required
package set. These RPMs contain the entitlement certificate and repo
definitions for RHEL-8 AWS RHUI repos, but RHUI will not work without
the image being imported with the proper Billing Code to AWS. So these
installed RHUI RPMs are technically useless on the RHEL-9 image, but
this approach is good enough to allow us to at least build and test
these images from configuration point of view.

Regenerate all image test cases because of the updated repositories.

Signed-off-by: Tomas Hozza <thozza@redhat.com>
2021-10-08 16:34:55 +01:00
Tomas Hozza
9497ef8ca9 Image tests: skip rpm-ostree-1-autovar.conf tmpfiles.d config on Fedora
The content of `/usr/lib/tmpfiles.d/rpm-ostree-1-autovar.conf` is
dynamically created and its lines are not ordered deterministically.
This causes the rpm-ostree based image test cases to fail often on
Fedora, because the diff of the expected and actual image-info report
always produces some different lines.

Add a new option `-skip-tmpfilesd-path` to `osbuild-image-tests`
accepting a tmpfiles.d configuration path, which should be ignored when
comparing the expected and actual image-info report. The option can be
specified multiple times and all paths will be ignored.

Modify the `image_tests.sh` test case to use the new option and ignore the
`/usr/lib/tmpfiles.d/rpm-ostree-1-autovar.conf` file when testing Fedora
images.

Signed-off-by: Tomas Hozza <thozza@redhat.com>
2021-10-08 16:21:25 +01:00
Jakub Rusz
e9c0f45bf7 tests: Update image_tests 2021-10-07 12:41:53 +02:00
sanne
cda54ef926 cloudapi/v1: Return status created in compose handler 2021-10-07 10:54:12 +02:00
Tomas Hozza
f9fbf5bd5e Regenerate affected image test cases
Regenerate affected image test cases with the image-info fix (affecting
mainly `tar` image type) and with the latest upstream `osbuild` build
(affecting rhel-85 qcow2 images).

Signed-off-by: Tomas Hozza <thozza@redhat.com>
2021-10-06 15:17:06 +02:00
Tomas Hozza
9ec2788ac8 generate-all-test-cases: allow specifying additional DNF repos
Add a new option `--repofrompath` allowing to specify additional DNF
repositories, which will be used on the Runner when installing any
packages (such as osbuild).

Extend the `test/README.md` to mention the new option. In addition,
specify some aspects of the script in more detail, because some of
them were not easy to figure out by users.

Signed-off-by: Tomas Hozza <thozza@redhat.com>
2021-10-06 15:17:06 +02:00
Jakub Rusz
1a7858c196 tests: enable koji.sh test on RHEL-9 2021-10-06 15:42:36 +03:00
Tomas Hozza
2aedd3da05 Test: regenerate all image test cases
Fix #1793

Signed-off-by: Tomas Hozza <thozza@redhat.com>
2021-10-04 10:48:21 +02:00
sanne
1e724be8e9 composer: More configuration of how composer is served
Allows you to disable tls
2021-10-02 14:27:02 +02:00
Ondřej Budai
5ed954bcf5 distro/rhel90: use qcow2 compat 1.1 for qcows
There's no reason to use 0.10 since we don't need to support running
this image on RHEL 6 anymore.
See https://bugzilla.redhat.com/show_bug.cgi?id=2008910

Signed-off-by: Ondřej Budai <ondrej@budai.cz>
2021-09-30 15:36:15 +02:00
sanne
5239e264bb test/regression: Adapt to new rhel-84-ga runners 2021-09-29 15:07:35 +02:00
sanne
2f328b0e97 workers: Backwards compatible api.openshift.com spec compliance
The main changes are:
- Kind, Href, Id fields for every object returned
- Attach operationIds to each request, return it for errors
- Errors are predefined and queryable
2021-09-27 13:10:05 +01:00
Alexander Todorov
5e206322a2 Disable regression-composer-works-behind-satellite.sh, Refs #1834 2021-09-24 17:03:53 +02:00