From 5e6f8489a919324d3ebeeac3aa238f1670e9514b Mon Sep 17 00:00:00 2001 From: Dan Schaper Date: Mon, 20 Feb 2017 11:45:58 -0800 Subject: [PATCH] Find 404 errors and relay message. Signed-off-by: Dan Schaper --- automated install/basic-install.sh | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/automated install/basic-install.sh b/automated install/basic-install.sh index 059f8f10..4fefbc0f 100755 --- a/automated install/basic-install.sh +++ b/automated install/basic-install.sh @@ -1161,22 +1161,24 @@ FTLinstall() { latesttag=$(curl -sI https://github.com/pi-hole/FTL/releases/latest | grep "Location" | awk -F '/' '{print $NF}') if [ ! "${latesttag}" ]; then - echo "::: failed (error in getting latest release location from GitHub)" + echo "failed (error in getting latest release location from GitHub)" return 1 fi if curl -sSL --fail "https://github.com/pi-hole/FTL/releases/download/${latesttag%$'\r'}/${binary}" -o "/tmp/pihole-FTL"; then # Check if we just downloaded text, or a binary file. if ! grep -qI '.' /tmp/pihole-FTL; then - echo "::: done" + echo "done" install -m 0755 /tmp/pihole-FTL /usr/bin touch /var/log/pihole-FTL.log /var/run/pihole-FTL.pid /var/run/pihole-FTL.port chmod 0666 /var/log/pihole-FTL.log /var/run/pihole-FTL.pid /var/run/pihole-FTL.port return 0 else - echo "::: failed (download of binary from Github failed)" + echo "failed (download of binary from Github failed)" return 1 fi echo "done" + else + echo "failed (URL not found.)" fi }