mirror of
https://github.com/pi-hole/pi-hole
synced 2025-01-08 23:20:56 +00:00
Add cron job to auto update block lists once a week.
This commit is contained in:
parent
963eacfe05
commit
dba1df9bf8
@ -78,5 +78,16 @@ sudo chmod 755 /usr/local/bin/chronometer.sh
|
|||||||
echo "Entering the event horizon..."
|
echo "Entering the event horizon..."
|
||||||
sudo /usr/local/bin/gravity.sh
|
sudo /usr/local/bin/gravity.sh
|
||||||
|
|
||||||
|
echo "Autoupdate script installation..."
|
||||||
|
crontab -l > /tmp/mycron
|
||||||
|
if grep -qi '\<gravity\>' /tmp/mycron
|
||||||
|
then
|
||||||
|
echo "Autoupdate already configured"
|
||||||
|
else
|
||||||
|
echo "0 * * * * sudo /usr/local/bin/gravity.sh" >> /tmp/mycron
|
||||||
|
crontab /tmp/mycron
|
||||||
|
fi
|
||||||
|
rm /tmp/mycron
|
||||||
|
|
||||||
echo "Restarting..."
|
echo "Restarting..."
|
||||||
sudo shutdown -r now
|
sudo shutdown -r now
|
||||||
|
Loading…
Reference in New Issue
Block a user