From d7197ecf15330c29618a42441f320c6dbd82f575 2022-06-08 22:26:00 From: Dennis Fink Date: 2022-06-08 22:26:00 Subject: [PATCH] Double quote to prevent globbing and word splitting. https://www.shellcheck.net/wiki/SC2086 --- diff --git a/init.sh b/init.sh index e8a3f63524dea12b025473f5ba95efcecd3b37c6..af5ea71a6fbf79fb84a7bcf723779344cab3a9e6 100755 --- a/init.sh +++ b/init.sh @@ -9,7 +9,7 @@ generateKey() { } deployKey() { - sshpass -p alarm ssh-copy-id -i ./sshKey.pub -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null -o PubkeyAuthentication=false alarm@$1 + sshpass -p alarm ssh-copy-id -i ./sshKey.pub -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null -o PubkeyAuthentication=false alarm@"$1" } # If keys are present, we just need to deploy it and destroy the SSH Agent