From a0db1dc8c9c5568bd7dd6f852ec447ae74e69fc8 Mon Sep 17 00:00:00 2001 From: Ismo Puustinen Date: Fri, 9 Feb 2018 13:29:50 +0200 Subject: [PATCH] hack/grab-profiles.sh: use double quotes in trap. The SSH_PID variable doesn't get expanded in the trap because of the single quotes. Change to double quotes. This is an example how the change works: $ FOO="bar" $ echo '$FOO' $FOO $ echo "$FOO" bar --- hack/grab-profiles.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/hack/grab-profiles.sh b/hack/grab-profiles.sh index bf45245ef95..3f6a22f4065 100755 --- a/hack/grab-profiles.sh +++ b/hack/grab-profiles.sh @@ -246,8 +246,8 @@ echo "Waiting for tunnel to be created..." kube::util::wait_for_url http://localhost:${tunnel_port}/healthz SSH_PID=$(pgrep -f "/usr/bin/ssh.*${tunnel_port}:localhost:8080") -kube::util::trap_add 'kill $SSH_PID' EXIT -kube::util::trap_add 'kill $SSH_PID' SIGTERM +kube::util::trap_add "kill $SSH_PID" EXIT +kube::util::trap_add "kill $SSH_PID" SIGTERM requested_profiles=$(echo ${requested_profiles} | xargs -n1 | LC_ALL=C sort -u | xargs) profile_components=$(echo ${profile_components} | xargs -n1 | LC_ALL=C sort -u | xargs)