From 911f9d623badd511e3adf2430b6dcf3f2b01cef3 Mon Sep 17 00:00:00 2001 From: Bob Mottram Date: Mon, 17 Oct 2016 14:10:10 +0100 Subject: [PATCH] Remove legacy freedns updater from crontab if needed --- src/freedombone-utils-dns | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/freedombone-utils-dns b/src/freedombone-utils-dns index b1f436f8..e8f62f18 100755 --- a/src/freedombone-utils-dns +++ b/src/freedombone-utils-dns @@ -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