Skip to content

Commit

Permalink
Merge pull request arevindh#28 from arevindh/arevindh-patch-1
Browse files Browse the repository at this point in the history
Update script
  • Loading branch information
arevindh authored Sep 27, 2019
2 parents 1f69a77 + 21b4bd7 commit 2886c52
Showing 1 changed file with 42 additions and 0 deletions.
42 changes: 42 additions & 0 deletions update.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
#!/bin/bash

if [[ $EUID -ne 0 ]]; then
echo "This script must be run as root"
exit 1
fi

whiptail --title "Pihole Speedtest Mod " --msgbox "Pihole Speedtest Mod Updater. \nSupport : https://github.com/arevindh/pihole-speedtest " 8 78

echo "Updating Pihole and Speedtest-mod"

#Revert admin to Pihole's newest
cd /var/www/html
rm -rf admin/
git clone https://github.com/pi-hole/AdminLTE admin

#Rever pihole's webpage
cd /opt/pihole/
rm webpage.sh
wget https://github.com/pi-hole/pi-hole/raw/master/advanced/Scripts/webpage.sh
chmod +x webpage.sh


#Update Pihole
pihole -up

#Update lastest speedtest-mod
cd /var/www/html
mv admin admin_org
git clone https://github.com/TooManyEggrolls/AdminLTE admin

#Update latest webpage.sh for speedtest-mod
cd /opt/pihole/
mv webpage.sh webpage.sh.org
wget https://github.com/TooManyEggrolls/pi-hole/raw/master/advanced/Scripts/webpage.sh
chmod +x webpage.sh

#Update version info
pihole updatechecker local


whiptail --title "Pihole Speedtest Mod" --msgbox "Update complete" 8 78

0 comments on commit 2886c52

Please sign in to comment.