From db9c8b610bc7f94256805ba2482038ab96985d0c Mon Sep 17 00:00:00 2001 From: starcalc Date: Tue, 30 Aug 2022 21:34:50 +0200 Subject: [PATCH] curl timeout 3minutes --- .drone.yml | 2 +- uploadfs.sh | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.drone.yml b/.drone.yml index 03cfe7f..e36e879 100644 --- a/.drone.yml +++ b/.drone.yml @@ -33,7 +33,7 @@ steps: for thisip in $(cat lastknownips) do echo "Current IP to upload is $thisip" - curl --insecure --no-progress-meter --fail-with-body --request POST --url "https://espota.ctdo.de/" --header "Content-Type: multipart/form-data" --form ip="$thisip" --form firmware=@.pio/build/d1_mini/firmware.bin --no-buffer + curl -m 180 --insecure --no-progress-meter --fail-with-body --request POST --url "https://espota.ctdo.de/" --header "Content-Type: multipart/form-data" --form ip="$thisip" --form firmware=@.pio/build/d1_mini/firmware.bin --no-buffer done - name: upload configs image: curlimages/curl diff --git a/uploadfs.sh b/uploadfs.sh index e92ff2e..9a2d095 100644 --- a/uploadfs.sh +++ b/uploadfs.sh @@ -6,7 +6,7 @@ do curhost = $(cat ${line} | cut -d ',' -f1) curip = $(cat ${line} | cut -d ',' -f2) echo "Host ${curhost} and IP ${curip}" - curl --insecure --no-progress-meter --fail-with-body --request POST --url "https://espota.ctdo.de/" --header "Content-Type: multipart/form-data" --form ip="$curip" --form spiffs=@.pio/build/d1_mini/spiffs_${curhost}.bin --no-buffer + curl -m 180 --insecure --no-progress-meter --fail-with-body --request POST --url "https://espota.ctdo.de/" --header "Content-Type: multipart/form-data" --form ip="$curip" --form spiffs=@.pio/build/d1_mini/spiffs_${curhost}.bin --no-buffer done < <(cat lastknownhostips) #!/bin/bash #while IFS="," read -r curhost curip