diff --git a/Containerfile.centos-stream10 b/Containerfile.centos-stream10 index e80a854..1524953 100644 --- a/Containerfile.centos-stream10 +++ b/Containerfile.centos-stream10 @@ -12,8 +12,9 @@ COPY --from=repos /etc/pki/rpm-gpg/RPM-GPG-KEY-centosofficial /etc/pki/rpm-gpg # rpm-ostree doesn't honor /etc/dnf/vars right now RUN for n in $(ls /etc/dnf/vars); do v=$(cat /etc/dnf/vars/$n); sed -ie s,\$${n},$v, c10s.repo; done RUN --mount=type=cache,target=/workdir --mount=type=bind,rw=true,src=.,dst=/buildcontext,bind-propagation=shared \ - cp -a /buildcontext /src && rm -vf /src/*.repo && cp -a c10s.repo /src && ls -al /src &&\ - rpm-ostree compose image --cachedir=/workdir --format=ociarchive --initialize /src/${MANIFEST} /buildcontext/out.ociarchive + cp -a /buildcontext /src && rm -vf /src/*.repo && cp -a c10s.repo /src && ls -al /src && \ + rpm-ostree compose image --image-config /buildcontext/centos-bootc-config.json \ + --cachedir=/workdir --format=ociarchive --initialize /src/${MANIFEST} /buildcontext/out.ociarchive FROM oci-archive:./out.ociarchive # Need to reference builder here to force ordering. But since we have to run diff --git a/Containerfile.centos-stream9 b/Containerfile.centos-stream9 index 4bdf46b..8ca6fca 100644 --- a/Containerfile.centos-stream9 +++ b/Containerfile.centos-stream9 @@ -33,7 +33,8 @@ COPY --from=repos /etc/yum.repos.d/centos.repo c9s.repo COPY --from=repos /etc/pki/rpm-gpg/RPM-GPG-KEY-centosofficial /etc/pki/rpm-gpg # rpm-ostree doesn't honor /etc/dnf/vars right now RUN for n in $(ls /etc/dnf/vars); do v=$(cat /etc/dnf/vars/$n); sed -ie s,\$${n},$v, c9s.repo; done -RUN --mount=type=cache,target=/workdir --mount=type=bind,rw=true,src=.,dst=/buildcontext,bind-propagation=shared rpm-ostree compose image --cachedir=/workdir --format=ociarchive --initialize /buildcontext/${MANIFEST} /buildcontext/out.ociarchive +RUN --mount=type=cache,target=/workdir --mount=type=bind,rw=true,src=.,dst=/buildcontext,bind-propagation=shared \ + rpm-ostree compose image --image-config /buildcontext/centos-bootc-config.json --cachedir=/workdir --format=ociarchive --initialize /buildcontext/${MANIFEST} /buildcontext/out.ociarchive FROM oci-archive:./out.ociarchive # Need to reference builder here to force ordering. But since we have to run diff --git a/Containerfile.fedora-40 b/Containerfile.fedora-40 index 840fd8d..bf17e0f 100644 --- a/Containerfile.fedora-40 +++ b/Containerfile.fedora-40 @@ -32,7 +32,8 @@ COPY --from=repos /etc/pki/rpm-gpg/RPM-GPG-KEY-fedora-* /etc/pki/rpm-gpg COPY . /src RUN rm -vf /src/*.repo COPY --from=repos /etc/yum.repos.d/*.repo /src -RUN --mount=type=cache,target=/workdir --mount=type=bind,rw=true,src=.,dst=/buildcontext,bind-propagation=shared rpm-ostree compose image --cachedir=/workdir --format=ociarchive --initialize /src/${MANIFEST} /buildcontext/out.ociarchive +RUN --mount=type=cache,target=/workdir --mount=type=bind,rw=true,src=.,dst=/buildcontext,bind-propagation=shared rpm-ostree compose image \ + --image-config /buildcontext/fedora-bootc-config.json --cachedir=/workdir --format=ociarchive --initialize /src/${MANIFEST} /buildcontext/out.ociarchive FROM oci-archive:./out.ociarchive # Need to reference builder here to force ordering. But since we have to run diff --git a/fedora-bootc-config.json b/fedora-bootc-config.json new file mode 100644 index 0000000..f5429f9 --- /dev/null +++ b/fedora-bootc-config.json @@ -0,0 +1,9 @@ +{ + "Labels": { + "containers.bootc": "1", + "bootc.diskimage-builder": "quay.io/centos-bootc/bootc-image-builder", + "redhat.id": "fedora", + "redhat.version-id": "40" + }, + "StopSignal": "SIGRTMIN+3" +}