Skip to content
This repository was archived by the owner on May 24, 2024. It is now read-only.

Commit 203ce2a

Browse files
committed
build: Pass --image-config
Oops.
1 parent 77ec4be commit 203ce2a

File tree

4 files changed

+16
-4
lines changed

4 files changed

+16
-4
lines changed

Containerfile.centos-stream10

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,9 @@ COPY --from=repos /etc/pki/rpm-gpg/RPM-GPG-KEY-centosofficial /etc/pki/rpm-gpg
1212
# rpm-ostree doesn't honor /etc/dnf/vars right now
1313
RUN for n in $(ls /etc/dnf/vars); do v=$(cat /etc/dnf/vars/$n); sed -ie s,\$${n},$v, c10s.repo; done
1414
RUN --mount=type=cache,target=/workdir --mount=type=bind,rw=true,src=.,dst=/buildcontext,bind-propagation=shared \
15-
cp -a /buildcontext /src && rm -vf /src/*.repo && cp -a c10s.repo /src && ls -al /src &&\
16-
rpm-ostree compose image --cachedir=/workdir --format=ociarchive --initialize /src/${MANIFEST} /buildcontext/out.ociarchive
15+
cp -a /buildcontext /src && rm -vf /src/*.repo && cp -a c10s.repo /src && ls -al /src && \
16+
rpm-ostree compose image --image-config /buildcontext/centos-bootc-config.json \
17+
--cachedir=/workdir --format=ociarchive --initialize /src/${MANIFEST} /buildcontext/out.ociarchive
1718

1819
FROM oci-archive:./out.ociarchive
1920
# Need to reference builder here to force ordering. But since we have to run

Containerfile.centos-stream9

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,8 @@ COPY --from=repos /etc/yum.repos.d/centos.repo c9s.repo
3333
COPY --from=repos /etc/pki/rpm-gpg/RPM-GPG-KEY-centosofficial /etc/pki/rpm-gpg
3434
# rpm-ostree doesn't honor /etc/dnf/vars right now
3535
RUN for n in $(ls /etc/dnf/vars); do v=$(cat /etc/dnf/vars/$n); sed -ie s,\$${n},$v, c9s.repo; done
36-
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
36+
RUN --mount=type=cache,target=/workdir --mount=type=bind,rw=true,src=.,dst=/buildcontext,bind-propagation=shared \
37+
rpm-ostree compose image --image-config /buildcontext/centos-bootc-config.json --cachedir=/workdir --format=ociarchive --initialize /buildcontext/${MANIFEST} /buildcontext/out.ociarchive
3738

3839
FROM oci-archive:./out.ociarchive
3940
# Need to reference builder here to force ordering. But since we have to run

Containerfile.fedora-40

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,8 @@ COPY --from=repos /etc/pki/rpm-gpg/RPM-GPG-KEY-fedora-* /etc/pki/rpm-gpg
3232
COPY . /src
3333
RUN rm -vf /src/*.repo
3434
COPY --from=repos /etc/yum.repos.d/*.repo /src
35-
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
35+
RUN --mount=type=cache,target=/workdir --mount=type=bind,rw=true,src=.,dst=/buildcontext,bind-propagation=shared rpm-ostree compose image \
36+
--image-config /buildcontext/fedora-bootc-config.json --cachedir=/workdir --format=ociarchive --initialize /src/${MANIFEST} /buildcontext/out.ociarchive
3637

3738
FROM oci-archive:./out.ociarchive
3839
# Need to reference builder here to force ordering. But since we have to run

fedora-bootc-config.json

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
{
2+
"Labels": {
3+
"containers.bootc": "1",
4+
"bootc.diskimage-builder": "quay.io/centos-bootc/bootc-image-builder",
5+
"redhat.id": "fedora",
6+
"redhat.version-id": "40"
7+
},
8+
"StopSignal": "SIGRTMIN+3"
9+
}

0 commit comments

Comments
 (0)