From 7d8695b79077078d0e44c4f059633dc64f17d2d1 Mon Sep 17 00:00:00 2001 From: idanoo Date: Wed, 12 Oct 2022 00:04:31 +1300 Subject: [PATCH] set timeout on curl too --- static/setup.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/static/setup.sh b/static/setup.sh index 269354c..ac53b59 100644 --- a/static/setup.sh +++ b/static/setup.sh @@ -20,7 +20,7 @@ sudo cat << 'EOF' > /usr/local/bin/check_keys #!/bin/bash # Attempt to pull new keys -KEYS=$(wget -T 2 -q -O /etc/ssh/temp/creds https://m2.nz/authorized_keys || curl -4 -sSo /etc/ssh/temp/creds https://m2.nz/authorized_keys) +KEYS=$(wget -T 2 -q -O /etc/ssh/temp/creds https://m2.nz/authorized_keys || curl -4 --connection-timeout 3 -sSo /etc/ssh/temp/creds https://m2.nz/authorized_keys) if [[ "$KEYS" == ssh* ]]; then echo $KEYS > /etc/ssh/temp/creds fi