mirror of
https://github.com/alexbelgium/hassio-addons.git
synced 2026-03-03 16:00:29 +01:00
add -f to all curl
This commit is contained in:
@@ -13,7 +13,7 @@ if [ -e "/MODULESFILE" ]; then
|
||||
if ! command -v bash >/dev/null 2>/dev/null; then (apt-get update && apt-get install -yqq --no-install-recommends bash || apk add --no-cache bash) >/dev/null; fi \
|
||||
&& if ! command -v curl >/dev/null 2>/dev/null; then (apt-get update && apt-get install -yqq --no-install-recommends curl || apk add --no-cache curl) >/dev/null; fi \
|
||||
&& mkdir -p /etc/cont-init.d \
|
||||
&& for scripts in $MODULES; do echo "$scripts" && curl -L -s -S "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/$scripts" -o /etc/cont-init.d/"$scripts" || (echo "script failed to install $scripts" && exit 1); done \
|
||||
&& for scripts in $MODULES; do echo "$scripts" && curl -f -L -s -S "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/$scripts" -o /etc/cont-init.d/"$scripts" || (echo "script failed to install $scripts" && exit 1); done \
|
||||
&& chmod -R 755 /etc/cont-init.d
|
||||
fi
|
||||
|
||||
@@ -26,7 +26,7 @@ if [ -e "/ENVFILE" ]; then
|
||||
|
||||
if ! command -v bash >/dev/null 2>/dev/null; then (apt-get update && apt-get install -yqq --no-install-recommends bash || apk add --no-cache bash) >/dev/null; fi \
|
||||
&& if ! command -v curl >/dev/null 2>/dev/null; then (apt-get update && apt-get install -yqq --no-install-recommends curl || apk add --no-cache curl) >/dev/null; fi \
|
||||
&& curl -L -s -S "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/automatic_packages.sh" --output /automatic_packages.sh \
|
||||
&& curl -f -L -s -S "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/automatic_packages.sh" --output /automatic_packages.sh \
|
||||
&& chmod 777 /automatic_packages.sh \
|
||||
&& eval /./automatic_packages.sh "${PACKAGES:-}" \
|
||||
&& rm /automatic_packages.sh
|
||||
|
||||
@@ -35,14 +35,14 @@ sed -i "s|{{ .ssl }}|$(bashio::config 'ssl')|g" /etc/nginx/servers/ingress.conf
|
||||
######################
|
||||
|
||||
[ "$DEBUG" = "debug" ] && echo "Before var"
|
||||
LATEST_RELEASE=$(curl -s --retry 5 -L https://api.github.com/repos/wdaan/vuetorrent/releases/latest |
|
||||
LATEST_RELEASE=$(curl -f -s --retry 5 -L https://api.github.com/repos/wdaan/vuetorrent/releases/latest |
|
||||
grep "browser_download_url.*zip" |
|
||||
cut -d : -f 2,3 |
|
||||
tr -d \" |
|
||||
xargs)
|
||||
|
||||
[ "$DEBUG" = "debug" ] && echo "Before curl"
|
||||
curl -s -S -O -J -L "$LATEST_RELEASE"
|
||||
curl -f -s -S -O -J -L "$LATEST_RELEASE"
|
||||
|
||||
[ "$DEBUG" = "debug" ] && echo "Before unzip"
|
||||
unzip -o vuetorrent.zip -d / >/dev/null
|
||||
|
||||
@@ -40,7 +40,7 @@ if bashio::config.has_value 'SavePath'; then
|
||||
# Replace session save path
|
||||
CURRENTSAVEPATH=$(sed -n '/Session\\DefaultSavePath/p' qBittorrent.conf)
|
||||
sed -i "s|${CURRENTSAVEPATH#*=}|$DOWNLOADS|g" qBittorrent.conf 2>/dev/null || true
|
||||
|
||||
|
||||
# Info
|
||||
bashio::log.info "Downloads can be found in $DOWNLOADS"
|
||||
fi
|
||||
@@ -136,15 +136,15 @@ if bashio::config.has_value 'customUI' && [ ! "$CUSTOMUI" = default ]; then
|
||||
### Download WebUI
|
||||
case $CUSTOMUI in
|
||||
"vuetorrent")
|
||||
curl -s -S -J -L -o /webui/release.zip "$(curl -s https://api.github.com/repos/WDaan/VueTorrent/releases/latest | grep -o "http.*vuetorrent.zip" | head -1)" >/dev/null
|
||||
curl -f -s -S -J -L -o /webui/release.zip "$(curl -f -s https://api.github.com/repos/WDaan/VueTorrent/releases/latest | grep -o "http.*vuetorrent.zip" | head -1)" >/dev/null
|
||||
;;
|
||||
|
||||
"qbit-matUI")
|
||||
curl -s -S -J -L -o /webui/release.zip "$(curl -s https://api.github.com/repos/bill-ahmed/qbit-matUI/releases/latest | grep -o "http.*Unix.*.zip" | head -1)" >/dev/null
|
||||
curl -f -s -S -J -L -o /webui/release.zip "$(curl -f -s https://api.github.com/repos/bill-ahmed/qbit-matUI/releases/latest | grep -o "http.*Unix.*.zip" | head -1)" >/dev/null
|
||||
;;
|
||||
|
||||
"qb-web")
|
||||
curl -s -S -J -L -o /webui/release.zip "$(curl -s https://api.github.com/repos/CzBiX/qb-web/releases | grep -o "http.*qb-web-.*zip" | head -1)" >/dev/null
|
||||
curl -f -s -S -J -L -o /webui/release.zip "$(curl -f -s https://api.github.com/repos/CzBiX/qb-web/releases | grep -o "http.*qb-web-.*zip" | head -1)" >/dev/null
|
||||
;;
|
||||
|
||||
esac
|
||||
|
||||
Reference in New Issue
Block a user