From d16de130775236abac0e32969690b0a4562533f5 Mon Sep 17 00:00:00 2001 From: "Henrique F. Simoes" Date: Fri, 13 Dec 2024 15:57:26 -0300 Subject: [PATCH] ioc: allow skipping all pruning steps. Pruning artifacts embeds several heuristics about what is worth keeping, and what should be removed after build. Such predefined pruning steps might miss corner cases where defining extra APP_DIRS is not enough. Introduce a knob to skip the pruning steps entirely to give users a immediate last resort option to use before a corrected version is eventually released. --- Dockerfile | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/Dockerfile b/Dockerfile index c97a33f..37e5a8e 100644 --- a/Dockerfile +++ b/Dockerfile @@ -46,8 +46,9 @@ FROM build-image AS pruned-build ARG APP_DIRS ARG RUNDIR +ARG SKIP_PRUNE -RUN lnls-prune-artifacts ${APP_DIRS} ${RUNDIR} +RUN if [ "$SKIP_PRUNE" != 1 ]; then lnls-prune-artifacts ${APP_DIRS} ${RUNDIR}; fi FROM base AS no-build @@ -81,10 +82,11 @@ ARG JOBS=1 ARG APP_DIRS ARG RUNDIR ARG SKIP_TESTS +ARG SKIP_PRUNE RUN make distclean && make -j ${JOBS} && make $([ "$SKIP_TESTS" != 1 ] && echo runtests) && make clean && make -C ${RUNDIR} -RUN lnls-prune-artifacts ${APP_DIRS} ${PWD} ${RUNDIR} +RUN if [ "$SKIP_PRUNE" != 1 ]; then lnls-prune-artifacts ${APP_DIRS} ${PWD} ${RUNDIR}; fi FROM base AS dynamic-link