2
0
mirror of https://github.com/xcat2/xcat-dep.git synced 2026-09-30 23:05:17 +00:00
Commit Graph

1080 Commits

Author SHA1 Message Date
Vinícius Ferrão b89dc6fa46 refactor(build): share repository target inference
Move repository path mapping into MockBuildUtils so callers can use it directly. Keep the openEuler and EL target rules unchanged.
2026-09-24 23:59:07 -03:00
Vinícius Ferrão 41e7dc90f1 docs: document native packaging tests 2026-09-22 23:09:27 -03:00
Vinícius Ferrão a41b0bd684 test: simplify openEuler native fixtures 2026-09-22 23:09:27 -03:00
Vinícius Ferrão 724602f485 fix(openeuler): integrate current dependency build and signing paths
Merge current master into the openEuler dependency branch. Preserve native
inputs and publisher signatures with the upstream timeout and keyring
helpers. Use the native repository path when carrying skipped builds.

Cover signed carry-over and mixed publisher/build-key verification.
2026-09-22 19:33:13 -03:00
Vinícius Ferrão 69b6bf1603 test(build): cover relative Genesis signing keyrings from the parent directory 2026-09-22 03:06:08 -03:00
Vinícius Ferrão aa48f53730 fix(build): resolve native Genesis signing paths before changing directories 2026-09-22 03:06:08 -03:00
Vinícius Ferrão 75117dc3cc test(build): cover native dependency signing and Genesis key forwarding 2026-09-22 02:57:09 -03:00
Vinícius Ferrão 4b79eaa463 fix(build): require signing for native openEuler dependency publication 2026-09-22 02:57:09 -03:00
Vinícius Ferrão face1c8328 docs(openeuler): describe native dependency inputs 2026-09-21 18:24:49 -03:00
Vinícius Ferrão a8fcf40e6b test(openeuler): cover native dependency builds 2026-09-21 18:24:02 -03:00
Vinícius Ferrão 0c0dfb787e feat(openeuler): build native dependency packages 2026-09-21 18:23:51 -03:00
Vinícius Ferrão a1fde97f2d test(build): distinguish native console package expectations 2026-09-21 18:22:52 -03:00
Daniel Hilst fc5c6d0375 Merge pull request #71 from VersatusHPC/fix/mockbuild-skip-perl-gate
fix(mockbuild-all): keep the published rpms of a skipped builder
2026-09-11 19:20:49 -03:00
Daniel Hilst 9fcfa467f6 Merge pull request #69 from VersatusHPC/fix/riscv64-perl-html-form
Pin perl-HTML-Form in the riscv64 dependency cell
2026-09-11 19:19:46 -03:00
Daniel Hilst 5ebc570288 Merge branch 'master' of xcat2/xcat-dep into fix/riscv64-perl-html-form
master added the common repository gate to the workflow and rewrote the
riscv64 comment of packages-manifest.conf after this branch started.

The workflow keeps both new prove lines. The two tests are unrelated.

The riscv64 comment takes master's text. This branch said the x86 boot
components are not built for riscv64; master then listed elilo-xcat,
syslinux-xcat and xnba-undi in the cell, because a riscv64 management
node serves the x86 nodes of a mixed cluster, so the branch sentence is
no longer true. The last line keeps this branch's statement: the perl
set is the EL10 one plus perl-HTML-Form. The pin itself merged without
a conflict, and t/riscv64_perl_cell.t passes on the merged cell.

Signed-off-by: Daniel Hilst <392820+dhilst@users.noreply.github.com>
2026-09-11 19:15:33 -03:00
Daniel Hilst 1d95b31285 Merge branch 'master' of xcat2/xcat-dep into fix/mockbuild-skip-perl-gate
master added the per-cell architecture rule (rpm_arch, rpm_in_cell) after
this branch started, so the two sides collide in three places.

The MockBuildUtils and t/mockbuild-all.t import lists take both sets of
names. Neither side removes a name the other needs.

MockBuildUtils.pm now held two definitions of rpm_arch, one from each
side, and Perl kept the later one. master's definition stands: it reads
the header of a file and falls back to the name suffix otherwise, which
is what its own tests and rpm_in_cell need. The branch definition is
removed. carry_over_rpms takes rpm_arch as an argument, so it keeps its
own architecture gate and its own message.

Signed-off-by: Daniel Hilst <392820+dhilst@users.noreply.github.com>
2026-09-11 19:13:42 -03:00
Daniel Hilst 201a6b1a6d Merge pull request #70 from VersatusHPC/fix/riscv64-deb-loaders
fix(xcat-dep): carry the x86 boot loaders in the riscv64 repositories
2026-09-11 18:57:58 -03:00
Daniel Hilst acb7311d0b Merge pull request #68 from VersatusHPC/feat/genesis-s390x
feat(genesis): package s390x images
2026-09-11 18:52:19 -03:00
Vinícius Ferrão b4578999f6 build(ci): run the mockbuild-all unit tests
t/mockbuild-all.t covers the manifest gate and the skip-run carry-over and
was not in the package test job. Its rpm fixtures skip where rpmbuild is
absent.

Signed-off-by: Vinícius Ferrão <2031761+viniciusferrao@users.noreply.github.com>
2026-09-10 01:12:20 -03:00
Vinícius Ferrão 25388ecdc2 docs(BUILD): skip runs keep the published rpms they did not build
Signed-off-by: Vinícius Ferrão <2031761+viniciusferrao@users.noreply.github.com>
2026-09-10 01:12:20 -03:00
Vinícius Ferrão 5ee949cc9a test(mockbuild-all): cover the skipped package carry-over
skipped_builder must place a source package with the builder required_pkgs
would skip and never claim the OpenEmbedded Genesis. carry_over_rpms must
keep every binary rpm of a skipped build whose source package the target
manifest still names, leave out whole any build the run already carries a
member of, and
die on an unreadable header, an unsigned or foreign-architecture member of
a selected build, or a package published at two versions. Paths with
spaces are covered. Both fail to import against the previous module.

Signed-off-by: Vinícius Ferrão <2031761+viniciusferrao@users.noreply.github.com>
2026-09-10 01:12:20 -03:00
Vinícius Ferrão 81205a1c81 fix(mockbuild-all): keep the published rpms of a skipped builder
Each run collects the rpms it built into its run repository, and deploy
stages the cell from that repository and gates it on the whole manifest,
which a skip run cannot satisfy: with --skip-perl there are no perl
packages, the gate reports them missing, and the deploy fails after the
build succeeded. The gate is right to check the whole manifest, since the
flags describe what this invocation built and not what the cell may lack.

After collection, the run repository now takes the binary rpms a skipped
builder published in the cell: whole builds, so subpackages the manifest
does not name stay too; only builds whose source package the target
manifest still names, so a dropped package is not republished; and only
builds of which the run carries no member yet, so generations of one build
never mix. The bump check, createrepo, the tarball and the deploy gate
then see the same complete set. The carry-over stops the run rather than
publish a partial or doubtful set: an rpm in the cell whose header cannot
be read, apart from the OpenEmbedded Genesis family that is pruned by
name, a member of a selected build the signing key did not sign, by signer
id and by rpmkeys --checksig, or whose digests do not verify when no key
is configured, a member of another architecture than the cell or noarch,
or a package published at more than one version. A package that was never
published is still reported missing, and a full run is unchanged. The
zero-artifact check applies only when a builder ran, so a run that skips
both package builders reaches the deploy.

Signed-off-by: Vinícius Ferrão <2031761+viniciusferrao@users.noreply.github.com>
2026-09-10 01:12:20 -03:00
Vinícius Ferrão 86a2aac183 refactor(mockbuild-all): split the rpmkeys keyring setup from the per-rpm check
verify_rpms_checksig built the isolated keyring and ran rpmkeys on every
rpm in one body. The keyring setup and the per-rpm verdict are now their
own helpers, so another caller can verify a single rpm against the signing
key. The gate behaves as before.

Signed-off-by: Vinícius Ferrão <2031761+viniciusferrao@users.noreply.github.com>
2026-09-09 23:42:47 -03:00
Vinícius Ferrão fbf7a5be2a docs(BUILD): riscv64 repositories carry the x86 boot loaders 2026-09-08 17:19:41 -03:00
Vinícius Ferrão a7c122b113 fix(mockbuild-all): scrub the chroot a noarch step built in
A noarch builder of a forcearch target runs in the native chroot of the
release, but its cleanup step was registered against the target
configuration. The step scrubbed a chroot that did not exist and left the
native bootstrap behind on every run, one per noarch step.

Compute the configuration once per step and scrub the same one it built in.
2026-09-08 17:19:40 -03:00
Vinícius Ferrão a17df594c9 test(mockbuild-all): cover the per-cell rpm architecture rule 2026-09-08 17:19:40 -03:00
Vinícius Ferrão 030259d7f6 fix(mockbuild-all): keep rpms of another architecture out of a target's cell
collect_rpms copied every binary rpm a builder produced. The syslinux builder
also produces syslinux, syslinux-extlinux and their debug rpms for the chroot
it runs in, so a forcearch target that builds the noarch boot loaders in the
native x86_64 chroot would have published x86_64 rpms in the riscv64 cell.
The completeness gate checks names and pins only, so it would have passed.

Keep an rpm only when it is noarch or carries the cell's architecture, read
from the rpm header. The rule lives in MockBuildUtils as rpm_in_cell.
2026-09-08 17:19:40 -03:00
Vinícius Ferrão 76ec6e081a test(mockbuild-all): pin the riscv64 boot loaders to the ppc64le pins
The riscv64 cell must carry elilo-xcat, grub2-xcat, syslinux-xcat and
xnba-undi at the pins of the EL10 ppc64le cell. 3 assertions fail against
the previous manifest.
2026-09-08 17:19:40 -03:00
Vinícius Ferrão 2b49e07c28 fix(mockbuild-all): build the x86 boot loaders for the riscv64 target
The forcearch riscv64 profile built grub2-xcat but not elilo-xcat,
syslinux-xcat or xnba-undi, and the rocky-10-riscv64-xcat cell did not list
them, so a riscv64 management node could not serve the x86 nodes of a mixed
cluster, unlike a ppc64le one.

Add the three to the profile and the cell, at the pins the EL10 ppc64le cell
uses. They are noarch and are built in the native x86_64 chroot, like
grub2-xcat. syslinux-xcat is marked noarch in the builder table, as its spec
declares, so the forcearch target does not try it in the emulated chroot,
where its ExclusiveArch excludes it. The target is now cross-built on x86_64
only, which the mock config states: a native riscv64 host could not build
syslinux-xcat either.
2026-09-08 17:19:40 -03:00
Vinícius Ferrão aef1d117d5 test(xcat-dep): require the boot loaders on the riscv64 deb sections
The manifest consistency check covered the amd64 and ppc64el sections. It
now covers the riscv64 sections too, so the 4 boot components must be listed
there. 12 assertions fail against the previous manifest.
2026-09-08 16:39:20 -03:00
Vinícius Ferrão 8b98ae9539 fix(xcat-dep): carry the x86 boot loaders in the riscv64 deb sections
The riscv64 sections of debs-manifest.conf listed grub2-xcat only. A riscv64
management node serves the x86 nodes of a mixed cluster, so its repository
must carry syslinux-xcat, elilo-xcat and xnba-undi, as the ppc64el sections
already require.

List the three in every riscv64 section. They are Architecture: all, built
once on amd64 and assembled into every index, so the build phase is
unchanged and the publish gate now verifies the riscv64 index carries them.
2026-09-08 16:39:20 -03:00
Daniel Hilst 35132a0c7d Merge pull request #67 from VersatusHPC/feat/ubuntu-riscv64-deps-v2
Build the Ubuntu dependency packages for riscv64
2026-09-08 12:08:28 -03:00
Vinícius Ferrão f5e60720f4 build(ci): run the riscv64 cell test
The runner already installs Parallel::ForkManager, which the builder loads, so
the test runs there rather than skipping.
2026-09-07 12:12:02 -03:00
Vinícius Ferrão ad97129dd5 test(xcat-dep): hold the riscv64 cell to the builder's package set
The assertion fails against the previous manifest, naming perl-HTML-Form as
the package the cell lacked. It reads the set from the builder, so a package
added to the builder later fails here until the cell names it.
2026-09-07 02:54:11 -03:00
Vinícius Ferrão 3022a31721 fix(xcat-dep): pin perl-HTML-Form in the riscv64 cell
perl-xCAT hard-requires perl(HTML::Form). EPEL supplies it on x86_64 and
ppc64le, so the EL9 and EL10 cells omit it, and the riscv64 cell copied that
omission. There is no EPEL for riscv64 and Rocky 10 riscv64 carries no
perl-HTML-Form in BaseOS, AppStream, CRB or extras, so dnf install xCAT could
not resolve on a riscv64 management node.
2026-09-07 02:54:11 -03:00
Vinícius Ferrão 016dda9775 feat(mockbuild-perl-packages): list the packages a run would build
--list-packages prints the set a run selects, after --epel-gap and --packages,
and exits before the root and mock checks. The riscv64 manifest cell has no
other repository behind it, so a test can now hold the cell to this list
without a build host.
2026-09-06 23:44:21 -03:00
Vinícius Ferrão 5ed8fd5799 test(xcat-dep): capture a descendant outliving its killed leader
The probe starts a descendant, kills the leader with SIGKILL, and asserts the
descendant is gone when the call returns. It fails against the previous
run_bounded, where the descendant survived.
2026-09-06 15:55:23 -03:00
Vinícius Ferrão 754567ec6c fix(xcat-dep): clear the build process group when its leader dies
run_bounded signalled the process group on a timeout and on a cancellation, but
not when the leader itself died. A SIGKILL, or the OOM killer, takes the shell
and leaves schroot and qemu in the group, holding the chroot and writing into
staging after the call reports the build finished.

Those processes are not children of this one, so there is nothing to wait for.
Signal the group on the way out.
2026-09-06 15:55:23 -03:00
Vinícius Ferrão afffcf39c9 test(xcat-dep): pin the exit status of a signalled child
The assertions cover a normal exit, the highest exit code, and death by TERM,
KILL and a core-dumping signal. run_bounded is driven through the same helper,
so the decoding and its caller cannot disagree.
2026-09-06 15:39:04 -03:00
Vinícius Ferrão ccbf05e758 fix(xcat-dep): record a worker the kernel killed as failed
A child killed by a signal leaves 0 in the high byte of its wait status. The
per-codename worker loop read only that byte, so a cancelled or OOM-killed
codename was counted as built, and the run could reach validation with the
staging tree that worker never finished.

One helper decodes a wait status for both the worker loop and run_bounded, and
reports 128 plus the signal for a child the kernel killed.
2026-09-06 15:39:03 -03:00
Vinícius Ferrão 043a7f6039 test(genesis): correct packager skip counts 2026-09-06 11:43:10 -03:00
Vinícius Ferrão 0e3e2461c3 fix(genesis): centralize package name prefixes 2026-09-06 11:43:10 -03:00
Vinícius Ferrão 55a9a6968e test(genesis): cover early manifest rejection 2026-09-06 11:30:42 -03:00
Vinícius Ferrão d063e86860 fix(genesis): validate repository manifests early 2026-09-06 11:30:42 -03:00
Vinícius Ferrão 09e068419b test(genesis): cover release capability ordering 2026-09-06 11:15:33 -03:00
Vinícius Ferrão 6828df8d67 fix(genesis): order release capability checks 2026-09-06 11:15:33 -03:00
Vinícius Ferrão 99d60459e7 docs(genesis): explain release formats 2026-09-06 10:54:29 -03:00
Vinícius Ferrão c8def3dc02 test(genesis): cover release compatibility 2026-09-06 10:54:29 -03:00
Vinícius Ferrão bea6826ac5 fix(genesis): preserve release compatibility 2026-09-06 10:54:28 -03:00
Vinícius Ferrão 22c26a5d57 fix(xcat-dep): block cancellation across ForkManager worker registration
ForkManager records a worker in run_on_start, which runs after the fork, so a
signal arriving in between reached a handler that did not know the worker. Both
worker pools now hold INT, TERM and HUP across start() and release them once the
parent has the pid.

The wait for a free slot happens before the mask is taken, or a cancellation
would stay pending for as long as the pool is full. With a single worker
ForkManager does not fork at all, so only a real child drops the inherited
forwarder, whose copy names siblings the parent already signals.
2026-09-06 04:56:53 -03:00