mirror of
https://gitlab.com/fedora/bootc/base-images.git
synced 2026-08-28 12:02:40 +00:00
The repo locations moved in F45+ [1] and so now when testing F44 in CI we end up with a failure like: ``` [2/3] STEP 2/2: RUN --mount=type=bind,from=repos,src=/,dst=/repos,rw <<EORUN (echo -e '--install\nltrace' > args.txt...) rpm-ostree version: 2026.2 error: Installing packages: No enabled repositories error: Executing compose install: ExitStatus(unix_wait_status(256)) Error executing command: Command '['rpm-ostree', 'compose', 'rootfs', '--source-root-rw=/repos', '/tmp/tmpmnq4sg6s.json', '/target-rootfs']' returned non-zero exit status 1. subprocess exited with status 1 ``` Let's drop using the rawhide image just for `repos` and use the repos baked into the image we built instead (which should match the target Fedora version we're testing). [1] https://fedoraproject.org/wiki/Changes/RelocateRpmRepoConfigsToUsr
34 lines
846 B
Text
34 lines
846 B
Text
# This test case exercises using the fedora-bootc image as a builder to
|
|
# generate a minimal target image, and then further extends it in a secondary
|
|
# phase.
|
|
|
|
# This is intentionally a locally built image
|
|
FROM localhost/fedora-bootc as builder
|
|
RUN <<EORUN
|
|
echo -e '--install\nltrace' > args.txt
|
|
/usr/libexec/bootc-base-imagectl --args-file args.txt build-rootfs --manifest=standard/manifest /target-rootfs
|
|
EORUN
|
|
|
|
# This pulls in the rootfs generated in the previous step
|
|
FROM scratch
|
|
COPY --from=builder /target-rootfs/ /
|
|
RUN <<EORUN
|
|
set -xeuo pipefail
|
|
. /usr/lib/os-release
|
|
test "$ID" = fedora
|
|
|
|
rpm -q ltrace
|
|
|
|
# And install a package
|
|
dnf -y install strace
|
|
dnf clean all
|
|
|
|
# Cleanup and lint
|
|
rm -rf /var/log /var/cache/* /var/lib/dnf
|
|
bootc container lint
|
|
EORUN
|
|
LABEL containers.bootc 1
|
|
ENV container=oci
|
|
STOPSIGNAL SIGRTMIN+3
|
|
CMD ["/sbin/init"]
|
|
|