diff --git a/joal/rootfs/run.sh b/joal/rootfs/run.sh index 8623ee0c6..a77f8272b 100644 --- a/joal/rootfs/run.sh +++ b/joal/rootfs/run.sh @@ -60,14 +60,16 @@ mkdir -p /var/log/nginx && touch /var/log/nginx/error.log declare TOKEN TOKEN=$(bashio::config 'secret_token') -UPSTREAM=$(bashio::config 'upstream') +#UPSTREAM=$(bashio::config 'upstream') VERBOSE=$(bashio::config 'verbose') || true mv -f /data/joal/config.json / || true -if [ $VERBOSE = true ]; then - wget -O /tmp/joal.tar.gz "https://github.com/anthonyraymond/joal/releases/download/$UPSTREAM/joal.tar.gz" +if [ $VERBOSE = true ]; then + curl -J -L -o /tmp/joal.tar.gz $(curl -s https://api.github.com/repos/anthonyraymond/joal/releases/latest | grep -o "http.*joal.tar.gz") + #wget -O /tmp/joal.tar.gz "https://github.com/anthonyraymond/joal/releases/download/$UPSTREAM/joal.tar.gz" else - wget -q -O /tmp/joal.tar.gz "https://github.com/anthonyraymond/joal/releases/download/$UPSTREAM/joal.tar.gz" + curl -s -S -J -L -o /tmp/joal.tar.gz $(curl -s https://api.github.com/repos/anthonyraymond/joal/releases/latest | grep -o "http.*joal.tar.gz") >/dev/null + #wget -q -O /tmp/joal.tar.gz "https://github.com/anthonyraymond/joal/releases/download/$UPSTREAM/joal.tar.gz" fi mkdir -p /data/joal tar zxvf /tmp/joal.tar.gz -C /data/joal >/dev/null