Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 4 additions & 3 deletions Justfile
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ integration_upgrade_img := integration_img + "-upgrade"
# composefs-sealeduki-sdboot: A system with a sealed composefs using systemd-boot
variant := env("BOOTC_variant", "ostree")
base := env("BOOTC_base", "quay.io/centos-bootc/centos-bootc:stream10")
buildroot_base := env("BOOTC_buildroot_base", "quay.io/centos/centos:stream10")
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this is a correct fix, but it is a bit of an ergonomic problem to have two bases and it'd probably simplify things to just reuse base for this by default.


testimage_label := "bootc.testimage=1"
# We used to have --jobs=4 here but sometimes that'd hit this
Expand All @@ -41,7 +42,7 @@ buildargs := "--build-arg=base=" + base + " --build-arg=variant=" + variant
# `just build --build-arg=base=quay.io/fedora/fedora-bootc:42`
build:
podman build {{base_buildargs}} -t {{base_img}}-bin {{buildargs}} .
./tests/build-sealed {{variant}} {{base_img}}-bin {{base_img}}
./tests/build-sealed {{variant}} {{base_img}}-bin {{base_img}} {{buildroot_base}}

# Build a sealed image from current sources.
build-sealed:
Expand Down Expand Up @@ -74,7 +75,7 @@ package: _packagecontainer
# This container image has additional testing content and utilities
build-integration-test-image: build
cd hack && podman build {{base_buildargs}} -t {{integration_img}}-bin -f Containerfile .
./tests/build-sealed {{variant}} {{integration_img}}-bin {{integration_img}}
./tests/build-sealed {{variant}} {{integration_img}}-bin {{integration_img}} {{buildroot_base}}
# Keep these in sync with what's used in hack/lbi
podman pull -q --retry 5 --retry-delay 5s quay.io/curl/curl:latest quay.io/curl/curl-base:latest registry.access.redhat.com/ubi9/podman:latest

Expand Down Expand Up @@ -118,7 +119,7 @@ test-tmt *ARGS: build-integration-test-image _build-upgrade-image
# Generate a local synthetic upgrade
_build-upgrade-image:
cat tmt/tests/Dockerfile.upgrade | podman build -t {{integration_upgrade_img}}-bin --from={{integration_img}}-bin -
./tests/build-sealed {{variant}} {{integration_upgrade_img}}-bin {{integration_upgrade_img}}
./tests/build-sealed {{variant}} {{integration_upgrade_img}}-bin {{integration_upgrade_img}} {{buildroot_base}}

# Assume the localhost/bootc-integration image is up to date, and just run tests.
# Useful for iterating on tests quickly.
Expand Down
5 changes: 4 additions & 1 deletion tests/build-sealed
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,9 @@ shift
# The output container image
output_image=$1
shift
# Buildroot base image for UKI build environment
buildroot_base=$1
shift
# Optional directory with secure boot keys; if none are provided, then we'll
# generate some under target/
secureboot=${1:-}
Expand Down Expand Up @@ -61,6 +64,6 @@ fi
runv podman build -t $output_image \
--build-arg=COMPOSEFS_FSVERITY=${cfs_digest} \
--build-arg=base=${input_image} \
--build-arg=buildroot=${BOOTC_buildroot_base} \
--build-arg=buildroot=${buildroot_base} \
--secret=id=key,src=${secureboot}/db.key \
--secret=id=cert,src=${secureboot}/db.crt -f Dockerfile.cfsuki .
Loading