diff --git a/Dockerfile b/Dockerfile index 001920c..4569f50 100644 --- a/Dockerfile +++ b/Dockerfile @@ -7,7 +7,8 @@ FROM scratch as bootstrap # Unpack the stage3 archive (which is downloaded and verifed externally). -ADD latest-stage3.tar.xz / +ARG ROOTFS_FILENAME="" +ADD ${ROOTFS_FILENAME} / # Set the profile. RUN eselect profile set "default/linux/amd64/17.1/no-multilib/systemd/merged-usr" # Replace /etc/portage/make.conf. diff --git a/build-image.sh b/build-image.sh index 7d8d636..c0a346d 100755 --- a/build-image.sh +++ b/build-image.sh @@ -91,6 +91,7 @@ podman tag rm "${REGISTRY}:latest" # Do not exit_err here. At least on first run # there is no latest tag to delete. # === Build the new image. -podman build "${PODMAN_BUILD_ARGS[@]}" || exit_err "Build failed." +podman build --build-arg=ROOTFS_FILENAME="${DISTFILES}/${ARCHIVE_FILE_NAME}" \ + "${PODMAN_BUILD_ARGS[@]}" || exit_err "Build failed." # vim:fileencoding=utf-8:ts=4:syntax=bash:expandtab