1
0
mirror of https://github.com/pi-hole/pi-hole synced 2024-12-22 23:08:07 +00:00

Be more verbose during install

This commit is contained in:
DL6ER 2017-02-13 14:47:06 +01:00
parent 09d6e73b0a
commit a052f397fe
No known key found for this signature in database
GPG Key ID: BB8EC0BC77973A30

View File

@ -1157,6 +1157,9 @@ if [[ "${reconfigure}" == true ]]; then
} }
FTLdownload() { FTLdownload() {
# Download suitable FTL binary
echo ":::"
echo "::: Downloading latest FTL binary..."
local machine=$(uname -m) local machine=$(uname -m)
@ -1188,20 +1191,28 @@ FTLdownload() {
latesttag=$(curl -s https://api.github.com/repos/pi-hole/FTL/releases/latest | grep "tag_name" | sed "s/.*: \"//;s/\",//;") latesttag=$(curl -s https://api.github.com/repos/pi-hole/FTL/releases/latest | grep "tag_name" | sed "s/.*: \"//;s/\",//;")
if [ ! "${latesttag}" ]; then if [ ! "${latesttag}" ]; then
echo "Error in getting latest release tag from GitHub" echo "::: failed (error in getting latest release tag from GitHub)"
return 1 return 1
fi fi
if curl -sSL --fail "https://github.com/pi-hole/FTL/releases/download/${latesttag}/${binary}" -o "/opt/pihole/pihole-FTL"; then if curl -sSL --fail "https://github.com/pi-hole/FTL/releases/download/${latesttag}/${binary}" -o "/opt/pihole/pihole-FTL"; then
echo "::: done"
return 0 return 0
else else
echo "::: failed (download of binary from Github failed)"
return 1 return 1
fi fi
} }
FTLinstall() { FTLinstall() {
# Download suitable FTL binary
echo ":::"
echo -n "::: Downloading latest FTL binary..."
install -m 0755 /opt/pihole/pihole-FTL /usr/local/bin install -m 0755 /opt/pihole/pihole-FTL /usr/local/bin
touch /var/log/pihole-FTL.log /var/run/pihole-FTL.pid /var/run/pihole-FTL.port 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 chmod 0666 /var/log/pihole-FTL.log /var/run/pihole-FTL.pid /var/run/pihole-FTL.port
echo "done"
} }
main() { main() {