test: propagate Copr NEVR pinning (eb7d75c) to bootc/fedora-iot-raw scripts - #196
Open
miabbott wants to merge 4 commits into
Open
test: propagate Copr NEVR pinning (eb7d75c) to bootc/fedora-iot-raw scripts#196miabbott wants to merge 4 commits into
miabbott wants to merge 4 commits into
Conversation
Member
CI StatusThe
RHEL/CentOS failuresThe RHEL and CentOS test failures are due to Testing Farm's repository allowlist — |
Listing greenboot/greenboot-default-health-checks by name after enabling the per-PR Copr repo isn't enough: dnf resolves the highest NEVRA across all enabled repos, and Copr snapshot builds conventionally use a Release starting at "0.<timestamp>...", the same convention official pre-GA/ rebuilt packages use. Whenever Fedora ships a greenboot release that outranks the current Copr build, dnf silently downloads the stock package and the test exercises unpatched code -- the same class of bug eb7d75c fixed for the ostree/osbuild-composer flow, just unpropagated to this script's SSH-based dnf5 download. Assisted-by: OpenCode (Claude Sonnet 5)
Same dnf NEVRA-precedence issue eb7d75c fixed for the ostree/osbuild- composer flow applies here: the generated Containerfile's dnf5 reinstall/ install calls resolve greenboot/greenboot-default-health-checks against every enabled repo, so a base-repo greenboot release that outranks the Copr snapshot's "0.<timestamp>..." release silently wins and the test exercises unpatched code. Assisted-by: OpenCode (Claude Sonnet 5)
Identical fix to the anaconda-iso sibling script: the generated Containerfile's dnf5 reinstall/install calls need to be scoped to the just-enabled Copr repo so a competing base-repo greenboot release can't outrank the Copr snapshot build and silently install unpatched code. Assisted-by: OpenCode (Claude Sonnet 5)
dnf reinstall --from-repo requires the exact same NEVR in the target repo, which fails when the base image ships a different Release than the Copr snapshot build. dnf install --from-repo won't replace an already-installed package. Switch to dnf download + local install, matching the ostree and compose-RPM patterns. Assisted-by: Claude (Anthropic) Signed-off-by: Paul Whalen <pwhalen@fedoraproject.org>
pcdubs
force-pushed
the
fix-copr-pin-on-178
branch
from
August 13, 2026 15:00
47988a0 to
e4d1d2e
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.
Problem
Commit
eb7d75c("test(ostree): pin greenboot to exact Copr NEVR") fixed a bug wherednfwould silently install a stock Fedora/RHELgreenbootpackage instead of the per-PR Copr build, because Copr snapshot builds use aReleasestarting at0.<timestamp>...which can be outranked by an official package's NEVRA. That fix only landed intests/greenboot-ostree.sh.This PR propagates the same fix to the three sibling scripts that still resolve
greenboot/greenboot-default-health-checksvia unscopeddnfcalls after enabling the per-PR Copr repo:tests/greenboot-fedora-iot-raw.shtests/greenboot-bootc-anaconda-iso.shtests/greenboot-bootc-qcow2.shThis was surfaced by Testing Farm failures on #193, where all three affected checks failed on an unrelated assertion because the VM had the stock
greenbootRPM installed instead of the Copr PR build. See #195 for the full root-cause writeup.Fix
Adds
--from-repo='copr:copr.fedorainfracloud.org:packit:fedora-iot-greenboot-rs-<PR_NUMBER>'to the relevantdnf download/dnf reinstall/dnf installcalls in each script, restricting package resolution to just the just-enabled Copr repo so no other repo can compete regardless of NEVRA. The exact repo-ID format was confirmed against both the dnf4 (dnf-plugins-core/copr.py) and dnf5 (dnf5/copr_plugin/copr_repo.cpp) plugin source — both constructcopr:<hub>:<owner>:<project>identically.The fix lands inside the
else(Copr) branch of theif [[ "${USE_COMPOSE_RPMS}" == true ]]; then ... else ... ficonditional that #178 introduced in both bootc scripts (now merged tomain), so it doesn't touch or affect the compose-RPM install path at all.Validation
Pending a
/testrun on this PR. Success criteria: the Ansible/journalctl log shows the post-#190INFO "No previous boot journal available..."message (not the pre-#190WARN) on at least onefedora-iot-rawand onebootctarget.rhel-10.2-bootc/rhel-9.8-ostreeare expected to still fail on this fork-originated PR due to an unrelated Testing Farm ranch ACL restriction — not in scope here.Closes #195
Updated context
The bootc scripts were further updated to replace the
dnf reinstall || dnf install --from-repoapproach withdnf download --from-repo+dnf install /tmp/copr-rpms/*.rpm.dnf reinstall --from-reporequires the exact same NEVR in the target repo, which fails when the base image ships a different Release than the Copr snapshot build (e.g. base image has0.16.3-0.fc44, Copr has0.16.3-0<timestamp>.pr196...fc44).dnf install --from-repowon't replace an already-installed package. Downloading first and installing from local RPMs avoids both issues, matching the ostree and compose-RPM patterns.🤖 Assisted-by: OpenCode (Claude Sonnet 5)