From 32c1677a90abb1acdacf61f436c43e9ed07777d4 Mon Sep 17 00:00:00 2001 From: Colin Walters Date: Thu, 9 Jan 2025 17:01:17 -0500 Subject: [PATCH] build-sys: Split up the rootfs from commit phases This allows someone forking this to inject their own content into the middle in a clean and obvious, container-native way. --- Containerfile | 22 ++++++++++++++++++---- 1 file changed, 18 insertions(+), 4 deletions(-) diff --git a/Containerfile b/Containerfile index ed14f01..049389a 100644 --- a/Containerfile +++ b/Containerfile @@ -39,15 +39,29 @@ COPY . /src WORKDIR /src RUN rm -vf /src/*.repo COPY --from=repos /etc/yum.repos.d/*.repo /src + +# Construct the base rootfs RUN --mount=type=cache,target=/workdir \ - --mount=type=bind,rw=true,src=.,dst=/buildcontext,bind-propagation=shared \ --mount=type=bind,from=repos,src=/,dst=/repos <