diff --git a/cluster/common.sh b/cluster/common.sh index 52c187c3f9..39cb0f0e21 100755 --- a/cluster/common.sh +++ b/cluster/common.sh @@ -314,7 +314,7 @@ function load-or-gen-kube-bearertoken() { # KUBE_TEMP function ensure-temp-dir { if [[ -z ${KUBE_TEMP-} ]]; then - KUBE_TEMP=$(mktemp -d -t kubernetes.XXXXXX) + export KUBE_TEMP=$(mktemp -d -t kubernetes.XXXXXX) trap 'rm -rf "${KUBE_TEMP}"' EXIT fi }