From 830141329068683777ffcb0abb36415168c2ac20 Mon Sep 17 00:00:00 2001 From: Victor Morales Date: Thu, 6 Dec 2018 06:17:34 -0800 Subject: Enable downloading binaries and containers The *download_run_once* kubespray config option allows to download container images only once then push to cluster nodes and the *download_localhost* option makes the installer node a delegate for pushing images while running the deployment with ansible. These two options pretends to reduce the amount of traffic during the deployment time of the Kubernetes cluster. Change-Id: I8239cebbf5c322ed52ae0a0bc8774e5e33aada3c Signed-off-by: Victor Morales Issue-ID: MULTICLOUD-425 --- deployments/build.sh | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'deployments/build.sh') diff --git a/deployments/build.sh b/deployments/build.sh index 90da6f95..c6d4a244 100755 --- a/deployments/build.sh +++ b/deployments/build.sh @@ -35,7 +35,9 @@ function _cleanup { echo "Cleaning previous execution" docker-compose kill image=$(grep "image.*k8plugin" docker-compose.yml) - docker images ${image#*:} -q | xargs docker rmi -f + if [[ -n ${image} ]]; then + docker images ${image#*:} -q | xargs docker rmi -f + fi docker ps -a --filter "status=exited" -q | xargs docker rm } -- cgit 1.2.3-korg