Commit graph

6656 commits

Author SHA1 Message Date
Yi He
85e176f438 ci: move edge test to testing-farm 2024-08-13 13:51:18 +02:00
Florian Schüller
09c5f5e374 osbuild-composer: activate deployment-channel reporting for splunk
followup of PR #4285
2024-08-12 15:38:56 +02:00
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
f2bd9e57f9 CI: temporarily disable image-tests on rhel-10 nightly 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
Jakub Rusz
66625ffea1 ci: run libvirt test on rhel-10 using rhos-01 runner
We can run this in openstack until we have the gcp image.
2024-08-12 08:39:05 +03:00
Jakub Rusz
0f902a67c9 CI: Add rules for scheduled RHEL-10 nightly 2024-08-12 08:39:05 +03:00
Jakub Rusz
d5995c13ef tests/ci: temporarily disable vmware tests on el-10
See COMPOSER-2328 for details.
2024-08-12 08:39:05 +03:00
Jakub Rusz
b3fc3919ca tests/api: add --net=host for podman command
Otherwise there are issues on el-10.
2024-08-12 08:39:05 +03:00
Jakub Rusz
ce9b75ac87 tests/api: Remove openscap profile for el-10
Currently there are no openscap profiles for el-10.
2024-08-12 08:39:05 +03:00
Jakub Rusz
22b42d9c95 CI: Add internal network for api tests 2024-08-12 08:39:05 +03:00
Jakub Rusz
306772aafa tests/CI: additional scheduling and loggin updates
Do not schedule gcp.sh on rhel-10 and centos-stream-10. Also improve
loggin for aws.sh and azure.sh as the cloud-image-val testing is
currently not preformed there.
2024-08-12 08:39:05 +03:00
Jakub Rusz
9a223500aa tests/regression: do not schedule skipped tests
Also fail in case it does get scheduled so we actually notice.
2024-08-12 08:39:05 +03:00
Alexander Todorov
dd82900f53 Replace GOVC_DATACENTER with GOVMOMI_DATACENTER ENV var
both are defined in CI, but the GOVC_ prefix doesn't match anything
else. Additionally this value is slightly different for vCenter8 and may
lead to failures if not unified.
2024-08-12 08:39:05 +03:00
Alexander Todorov
fdb8cfb26a Temporarily disable testing with Satellite on el10
Related: COMPOSER-2264
2024-08-12 08:39:05 +03:00
Tomáš Hozza
6c454abd13 Test/repositories: delete EOL F37 and F38 repos
Signed-off-by: Tomáš Hozza <thozza@redhat.com>
2024-08-12 08:39:05 +03:00
Tomáš Hozza
510f3cf1da Test/repositories: update el10.0 snapshots
Signed-off-by: Tomáš Hozza <thozza@redhat.com>
2024-08-12 08:39:05 +03:00
Tomáš Hozza
083d709d1b Test/repositories: update c10s snapshots
Signed-off-by: Tomáš Hozza <thozza@redhat.com>
2024-08-12 08:39:05 +03:00
Tomáš Hozza
d4c8f74ee4 Tests/regression-satellite: fix permission denied error in cleanup()
The cleanup() function cats the httpd log and error file, but did not
use sudo, which failed on permissions. Fix that.

Signed-off-by: Tomáš Hozza <thozza@redhat.com>
2024-08-12 08:39:05 +03:00
Tomáš Hozza
df161ad23d Tests/cross-distro.sh: ignore upstream repos suffixed with 'no-aux-key'
The test case mistakenly takes into consideration also upstream repo
definitions with the 'no-aux-key' suffix, which are however never
installed by RPMs with this name.

Signed-off-by: Tomáš Hozza <thozza@redhat.com>
2024-08-12 08:39:05 +03:00
Tomáš Hozza
239b69261a Test: dot-notation backward compatibility is not supported on el10
The backward compatibility layer to support also distro / repo names
without a dot is no longer supported since RHEL-10 onwards. Disable the
test case on el10.

Signed-off-by: Tomáš Hozza <thozza@redhat.com>
2024-08-12 08:39:05 +03:00
Tomáš Hozza
764949a0b9 weldr-distro-dot-notation-and-aliases.sh: remove extra slash
Remove an extra forward slash in a directory path definition.

Signed-off-by: Tomáš Hozza <thozza@redhat.com>
2024-08-12 08:39:05 +03:00
Tomáš Hozza
7627838352 SPEC: don't install repos suffixed with 'no-aux-key'
Repository definitions suffixed with 'no-aux-key' were previously
mistakenly installed in RPMs. Fix that.

Signed-off-by: Tomáš Hozza <thozza@redhat.com>
2024-08-12 08:39:05 +03:00
Tomáš Hozza
2f9266e240 Tests/api.sh: test only a subset of image types on el10
c10s/el10 for now support only a subset of image types.

Signed-off-by: Tomáš Hozza <thozza@redhat.com>
2024-08-12 08:39:05 +03:00
Alexander Todorov
7668911038 Add version_id for regression test scripts for rhel-10
note: may fail in the same way 9.5 does (SSL certificates) and may need
to be disabled. See code few lines above this change.
2024-08-12 08:39:05 +03:00
Alexander Todorov
a909cae0dc Skip test b/c image-installer unsupoorted on cs10 & rhel-10 for now 2024-08-12 08:39:05 +03:00
Alexander Todorov
0a30d79d9b Skip testing in GCP - unsupported for now 2024-08-12 08:39:05 +03:00
Alexander Todorov
f1ac9cc7a0 Disable cloud-image-val because of CLOUDX-994 2024-08-12 08:39:05 +03:00
Alexander Todorov
f316ebff9f Define el10 variant for libvirt
Signed-off-by: Tomáš Hozza <thozza@redhat.com>
2024-08-12 08:39:05 +03:00
Tomáš Hozza
eae8b50ad3 CI: don't run some tests on el9.5-nightly aarch64
Runners in some jobs suggest, that the intention was to run them only on
x86_64. However, there were two instances when such job was also run on
aarch64 el9.5-nightly runner. Let's assume that this was a copy&paste
error and delete such cases.

Signed-off-by: Tomáš Hozza <thozza@redhat.com>
2024-08-12 08:39:05 +03:00
Alexander Todorov
06a897390a Start running tests on rhel-10.0-nightly
Signed-off-by: Tomáš Hozza <thozza@redhat.com>
2024-08-12 08:39:05 +03:00
Alexander Todorov
0f2558d72e Use --net=host when running podman, workaround RHEL-32374 2024-08-12 08:39:05 +03:00
Alexander Todorov
dedc6c970d Define cs10 variant for libvirt 2024-08-12 08:39:05 +03:00
Alexander Todorov
6aa02bdd4d Start running tests on centos-stream-10 2024-08-12 08:39:05 +03:00
Alexander Todorov
39d91bcb4e There is no EPEL for EL10 yet so use a custom COPR repository 2024-08-12 08:39:05 +03:00
Florian Schüller
9006836afc logrus: add deployment channel as field to the logs 2024-08-07 12:32:57 +02:00
Gianluca Zuccarelli
2da3a73308 cloudapi: json tailoring options
Add support for json tailoring files in the cloudapi. Expand the tests
to check that the options returned are okay and that tailoring options
and json tailoring options can't be provided at the same time.
2024-08-07 12:06:28 +02:00
Gianluca Zuccarelli
16180e9c58 blueprint/customizations: json tailoring
Add support to the blueprints for json tailoring files
2024-08-07 12:06:28 +02:00
Gianluca Zuccarelli
4c225f7d66 cloudapi: openscap tailoring tests
Add an initial test for OpenSCAP tailoring customizations since we will
be expanding the tailoring options to support json tailoring.
2024-08-07 12:06:28 +02:00
Gianluca Zuccarelli
c9972f7da8 go.mod: update osbuild/images to v0.74.0 2024-08-07 12:06:28 +02:00
schutzbot
3789ff4ce8 Post release version bump
[skip ci]
2024-08-07 08:14:59 +00:00
Michael Vogt
86b1143923 osbuildexecutor: show full osbuild exector on json decode errors
This is a short term workaround to get better visibility why
the osbuild executor sometimes sends non-json data. When reading
the result from the executor the entire output is now read and
if the json parsing goes wrong it will use the entire body
in the error message for better debug visibility.
2024-08-05 14:51:40 +02:00
Florian Schüller
0a68fe3005 Makefile: implement helper to process OpenShift templates
just for manual checks if the template syntax is fine
and align with the github action to use the same code
2024-08-02 04:01:02 +02:00
Michael Vogt
1d0232ffc6 osbuild-worker: rework the workerClientErrorFrom() error
The workerClientErrorFrom() was returning an `*clienterrors.Error` and
an `error` (if something with the conversation goes wrong.

But the calling code was expecting that even if an `error` is returned
the `*clienterrors.Error` is still valid. The caller would then just
log the error. As returning a valid `value` even when there is an
`error` is an unexpected pattern this commit changes the code to
always return a `*clienterrors.Error` and log any issue via the
logger.
2024-08-01 17:25:16 +02:00
Sanne Raymaekers
dc389eaa71 cloud/awscloud: fix nil pointer dereference
When the cleanup function gets called, there's a chance the Instnace
field isn't populated yet, so store the instance ID separately and wait
for it to be terminated in case it's present.

The error would produce the following trace:
```
goroutine 1 [running]:
...
main.(*OSBuildJobImpl).Run.func1()
    osbuild/osbuild-composer/cmd/osbuild-worker/jobimpl-osbuild.go:404 +0xc5
panic({0x55e2a76a1e40?, 0x55e2a906d2f0?})
    /usr/lib/golang/src/runtime/panic.go:920 +0x270
github.com/osbuild/osbuild-composer/internal/cloud/awscloud.(*AWS).deleteFleetIfExists(0xc000faa840, 0xc0012718c0)
    osbuild/osbuild-composer/internal/cloud/awscloud/secure-instance.go:441 +0x175
github.com/osbuild/osbuild-composer/internal/cloud/awscloud.(*AWS).TerminateSecureInstance(0x55e2a90825e0?, 0x2?)
    osbuild/osbuild-composer/internal/cloud/awscloud/secure-instance.go:192 +0x1d
github.com/osbuild/osbuild-composer/internal/cloud/awscloud.(*AWS).RunSecureInstance.func1()
    osbuild/osbuild-composer/internal/cloud/awscloud/secure-instance.go:75 +0x69
github.com/osbuild/osbuild-composer/internal/cloud/awscloud.(*AWS).RunSecureInstance(0xc000faa840, {0xc000afeade, 0x10}, {0x0, 0x0}, {0x0, 0x0}, {0xc001120f30, 0x24})
    osbuild/osbuild-composer/internal/cloud/awscloud/secure-instance.go:169 +0x12a7
...
```
2024-08-01 10:58:08 +02:00
Florian Schüller
54904d47da Change log_level for the service to json
This is to be inline with image-builder and to
enable decoding in splunk
2024-07-31 17:46:01 +02:00
Michael Vogt
573b349f16 clienterrors: rename WorkerClientError to clienterrors.New
The usual convention to create new object is to prefix `New*` so
this commit renames the `WorkerClientError`. Initially I thought
it would be `NewWorkerClientError()` but looking at the package
prefix it seems unneeded, i.e. `clienterrors.New()` already
provides enough context it seems and it's the only error we
construct.

We could consider renaming it to `clienterror` (singular) too
but that could be a followup.

I would also like to make `clienterror.Error` implement the
`error` interface but that should be a followup to make this
(mechanical) rename trivial to review.
2024-07-31 17:04:58 +02:00
Sanne Raymaekers
09445a1030 dbjobqueue: correct error wrapping
Preserve context.DeadlineExceeded errors through correct error
wrapping. This will reduce error-level logging noise in the worker.
2024-07-31 13:34:13 +02:00
Achilleas Koutsou
769b04b862 test/api: silent dump_db()
When cleaning up api tests, the build job results are dumped from the
database to store in build-result.txt and are printed to the runner log
at the same time.  This makes it very difficult to read results as the
database dump prints very long lines that flood the job log.  The result
isn't really readable (or useful) unless the file is downloaded
separately.

Silence the `tee` command so that the file is created but no output is
printed from the db dump.
2024-07-29 15:05:15 +02:00