Remove legacy freedns updater from crontab if needed

This commit is contained in:
Bob Mottram 2016-10-17 14:10:10 +01:00
parent 48cb40c2d3
commit 911f9d623b
1 changed files with 3 additions and 0 deletions

View File

@ -112,6 +112,9 @@ function create_freedns_updater {
if [ -f /usr/bin/dynamicdns ]; then
rm /usr/bin/dynamicdns
fi
if grep -q "dynamicdns" /etc/crontab; then
sed -i '/dynamicdns/d' /etc/crontab
fi
# add the update command to cron
if ! grep -q "/usr/local/bin/freedombone-freedns" /etc/crontab; then