forked from coreos/rpm-ostree
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by: Colin Walters <[email protected]>
- Loading branch information
Showing
3 changed files
with
43 additions
and
0 deletions.
There are no files selected for viewing
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -216,6 +216,19 @@ jobs: | |
run: tar -C / -xzvf install.tar | ||
- name: Integration tests | ||
run: env TMPDIR=/var/tmp ./tests/encapsulate.sh | ||
test-build-chunked-oci: | ||
name: "experimental build-chunked-oci tests" | ||
needs: build-c9s | ||
runs-on: ubuntu-24.04 | ||
steps: | ||
- name: Checkout repository | ||
uses: actions/checkout@v4 | ||
- name: Download build | ||
uses: actions/[email protected] | ||
with: | ||
name: install-c9s.tar | ||
- name: Integration tests | ||
run: cd tests/build-chunked-oci && tar -xzvf ../../install.tar && podman build -v $(pwd)/usr/bin:/ci -t localhost/test . | ||
build-c9s: | ||
name: "Build (c9s)" | ||
runs-on: ubuntu-latest | ||
|
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
FROM quay.io/fedora/fedora-bootc:41 as rootfs | ||
RUN <<EORUN | ||
set -xeuo pipefail | ||
# Remove some high level superfulous stuff | ||
dnf -y remove sos NetworkManager-tui vim nano | ||
# And this only targets VMs, so flush out all firmware | ||
rpm -qa --queryformat=%{NAME} | grep -Fe '-firmware-' | xargs dnf -y remove | ||
# We don't want any python, and we don't need rpm-ostree either. | ||
dnf -y remove python3 rpm-ostree{,-libs} | ||
bootc container lint | ||
EORUN | ||
|
||
# Note that the GHA flow in ci.yml injects a binary from C9S. | ||
FROM quay.io/centos/centos-bootc:stream9 as builder | ||
RUN --mount=type=bind,rw=true,src=.,dst=/buildcontext,bind-propagation=shared \ | ||
--mount=from=rootfs,dst=/rootfs <<EORUN | ||
set -xeuo pipefail | ||
# Pull in the binary we just built; if you're doing this locally you'll want | ||
# to e.g. run `podman build -v target/release/rpm-ostree:/ci/rpm-ostree`. | ||
install /ci/rpm-ostree /usr/bin/ | ||
rm /buildcontext/out.oci -rf | ||
rpm-ostree experimental compose build-chunked-oci --bootc --format-version=1 \ | ||
--rootfs=/rootfs --output /buildcontext/out.oci | ||
EORUN | ||
|
||
FROM oci:./out.oci | ||
# Need to reference builder here to force ordering. But since we have to run | ||
# something anyway, we might as well cleanup after ourselves. | ||
RUN --mount=type=bind,from=builder,src=.,target=/var/tmp \ | ||
--mount=type=bind,rw=true,src=.,dst=/buildcontext,bind-propagation=shared rm /buildcontext/out.oci -rf |
Empty file.