From 72dcb87f510436d60ad0c370e6b90692ebf5b213 Mon Sep 17 00:00:00 2001 From: auphelia Date: Thu, 24 Oct 2024 14:41:37 +0100 Subject: [PATCH] [Infra] Re-use build extra env vars to enable no cache option --- run-docker.sh | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/run-docker.sh b/run-docker.sh index 8bf6440d4..69c998c46 100755 --- a/run-docker.sh +++ b/run-docker.sh @@ -192,9 +192,7 @@ if [ -d "$FINN_XRT_PATH" ];then fi if [ "$FINN_DOCKER_NO_CACHE" = "1" ]; then - export NO_CACHE_STRING="--no-cache" -else - export NO_CACHE_STRING="" + FINN_DOCKER_BUILD_EXTRA+="--no-cache" fi # Build the FINN Docker image @@ -202,7 +200,7 @@ if [ "$FINN_DOCKER_PREBUILT" = "0" ] && [ -z "$FINN_SINGULARITY" ]; then # Need to ensure this is done within the finn/ root folder: OLD_PWD=$(pwd) cd $SCRIPTPATH - docker build -f docker/Dockerfile.finn --build-arg XRT_DEB_VERSION=$XRT_DEB_VERSION --build-arg SKIP_XRT=$FINN_SKIP_XRT_DOWNLOAD --build-arg LOCAL_XRT=$LOCAL_XRT --tag=$FINN_DOCKER_TAG $FINN_DOCKER_BUILD_EXTRA $NO_CACHE_STRING . + docker build -f docker/Dockerfile.finn --build-arg XRT_DEB_VERSION=$XRT_DEB_VERSION --build-arg SKIP_XRT=$FINN_SKIP_XRT_DOWNLOAD --build-arg LOCAL_XRT=$LOCAL_XRT --tag=$FINN_DOCKER_TAG $FINN_DOCKER_BUILD_EXTRA . cd $OLD_PWD fi