fix: add missing build type behavior

- Add argument to container file.

Signed-off-by: Gabriel Nützi <gnuetzi@gmail.com>
This commit is contained in:
Gabriel Nützi
2024-07-14 11:31:31 +02:00
parent 09b3d7876b
commit dc5da18118
2 changed files with 36 additions and 21 deletions

View File

@@ -20,6 +20,10 @@ ADD /root/ /root/
ADD /etc/ /etc/
ADD /home/ /home/
# The build type: either `dev` or `prod`
# In `dev` mode: the package manager will not be deleted.
ARG BUILD_TYPE=prod
# Allow image-builders to choose another version besides "latest" should
# an incompatible change be introduced.
ARG RUNNER_VERSION=latest
@@ -35,9 +39,11 @@ ARG TARGETARCH=amd64
ARG PRUNE_INTERVAL=daily # see systemd.timer for allowable values
# All-in-one packaging/image-setup script to keep things simple.
RUN PRUNE_INTERVAL=${PRUNE_INTERVAL} \
RUNNER_VERSION=${RUNNER_VERSION} \
bash /root/setup.sh
RUN \
PRUNE_INTERVAL=${PRUNE_INTERVAL} \
RUNNER_VERSION=${RUNNER_VERSION} \
BUILD_TYPE=${BUILD_TYPE} \
bash /root/setup.sh
VOLUME /cache /home/podman/.local/share/containers
ENTRYPOINT /lib/systemd/systemd