ci: Build operator images via the shared builder workflow - #626
Closed
dervoeti wants to merge 1 commit into
Closed
Conversation
dervoeti
force-pushed
the
feat/slsa-l3-shared-builder
branch
from
August 6, 2026 16:35
381245c to
46ae325
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Follow-up to stackabletech/actions#122. This switches the operator image build over to it.
Currently every operator builds in its own top-level
build.yaml, which is SLSA Build Level 2. GitHub's documented mechanism for Build Level 3 is that the build runs in a reusable workflow, separate from the workflow calling it (see https://docs.github.com/en/actions/concepts/security/artifact-attestations#slsa-levels-for-artifact-attestations). Delegating tostackabletech/actions/.github/workflows/reusable_build_container_image.yamlgives us that split, and all 16 operators end up sharing one build definition instead of 16 generated copies.Only source-level build parameters are passed, so this workflow cannot hand the builder a digest and obtain provenance for an image it did not build.
build-container-imageis now a call to the shared builder instead of a runner/arch matrix. The builder builds both architectures, pushes and attests each one, then assembles, signs and attests the index.publish-index-manifest,provenance-ociandprovenance-quayare gone. The builder does all three.operator-versionjob, which only computes the version and exposes it as an output.publish-helm-chartandopenshift-preflight-checknow take it from there instead of from the build job.detect-changes,cargo-udeps,publish-helm-chart,openshift-preflight-check,finishedandnotifyare otherwise unchanged.The
sedthat rewroteCargo.tomlis gone. The builder does it through itscargo-workspace-versioninput, because caller-supplied shell must not run on the builder's runners.It is needed at all because the operator binary reports
CARGO_PKG_VERSION(asbuilt_info::PKG_VERSION), which ends up in the startup log and is passed toprint_yaml_schema(), so it is stamped into the generated CRDs. TheVERSIONbuild argument only feeds image labels and the README text, so it cannot replace it.Dropped setup steps
The image build job loses its Nix install, its pinned Rust toolchain and its apt build dependencies. These are left over from when the operator was compiled on the runner. The compile now happens inside the container, where
ubi10-rust-buildersupplies its own toolchain through itsONBUILDstage.cargo-udepsdoes genuinely compile on the runner, so it keeps its own apt step and its own toolchain install and is untouched.