diff --git a/ztp/resource-generator/Makefile b/ztp/resource-generator/Makefile index d550f1ad94..7d86f96475 100644 --- a/ztp/resource-generator/Makefile +++ b/ztp/resource-generator/Makefile @@ -28,8 +28,8 @@ push: ## Push to registry ${REG_URL} export: ## Copy resources from container image to out/ directory mkdir -p out - podman run --rm ${IMAGE_NAME}:${VERSION} extract /home/ztp --tar | tar x -C out + podman run --rm --log-driver=none ${IMAGE_NAME}:${VERSION} extract /home/ztp --tar | tar x -C out mkdir -p out/kustomize - podman run --rm ${IMAGE_NAME}:${VERSION} extract /kustomize --tar | tar x -C out/kustomize + podman run --rm --log-driver=none ${IMAGE_NAME}:${VERSION} extract /kustomize --tar | tar x -C out/kustomize all: build export push diff --git a/ztp/resource-generator/entrypoints/extract b/ztp/resource-generator/entrypoints/extract index b58adf7f1d..c249f0820c 100755 --- a/ztp/resource-generator/entrypoints/extract +++ b/ztp/resource-generator/entrypoints/extract @@ -13,12 +13,11 @@ if [[ $1 == "-h" || $1 == "--help" || $1 == "help" ]]; then echo echo " Important: With podman, add '--log-driver=none' to prevent podman from hanging with large data sent to stdout," echo " and '--rm' to avoid creating unneeded persistent container image" - echo " podman run \$THIS_CONTAINER $(basename $0) /home/ztp --tar | tar -C ./out" echo echo " $(basename $0) srcPath dstPath" echo " Export the given directory structure to the destination path (should be mounted as a container volume)" echo " Example:" - echo " podman run \$THIS_CONTAINER -v ./out:/out:Z $(basename $0) /home/ztp /out" + echo " podman run --rm \$THIS_CONTAINER -v ./out:/out:Z $(basename $0) /home/ztp /out" exit 1 fi