fix(quickget): exit on curl failure in web_get

Add exit 1 after curl failure handling in web_get

- Exit immediately when a download via curl fails
- Prevent continuing to build invalid VM configs after failed download

Fixes #1625
This commit is contained in:
Martin Wimpress 2026-01-25 13:39:13 +00:00 committed by Martin Wimpress
parent 57cd52b1dc
commit a56a43342d
1 changed files with 1 additions and 0 deletions

View File

@ -1618,6 +1618,7 @@ function web_get() {
if ! curl --disable --progress-bar --location --output "${DIR}/${FILE}" --continue-at - --user-agent "${USER_AGENT}" "${HEADERS[@]}" -- "${URL}"; then
echo "ERROR! Failed to download ${URL} with curl."
rm -f "${DIR}/${FILE}"
exit 1
fi
}