Skip to content

Commit

Permalink
Merge pull request #4 from jmarhee/jmarhee/retrieve-script-while-wait
Browse files Browse the repository at this point in the history
Updates scripts/retrieve_kubeconfig.sh to remove sleep, now just wait…
  • Loading branch information
jmarhee authored Jun 17, 2024
2 parents 31e13a6 + 4dedd1d commit 2c5e46f
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion scripts/retrieve_kubeconfig.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,10 @@
CONTROLLER_IP=$1
KEY_PATH=$2

/bin/sleep 180 ; \
while ! /usr/bin/ssh -i $KEY_PATH \
-o StrictHostKeyChecking=no \
-o UserKnownHostsFile=/dev/null -q \
root@$CONTROLLER_IP "ls /etc/rancher/k3s/k3s.yaml" &> /dev/null; do sleep 1; done && \
if [[ "$OSTYPE" == "darwin"* ]]; then
CONFIG=$(/usr/bin/ssh -i \
$KEY_PATH \
Expand Down

0 comments on commit 2c5e46f

Please sign in to comment.