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
pull/6/head
Ismo Puustinen 2018-02-09 13:29:50 +02:00
parent 1fe4192b67
commit a0db1dc8c9
1 changed files with 2 additions and 2 deletions

View File

@ -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)