X-Git-Url: https://iankelling.org/git/?a=blobdiff_plain;f=dynamic-ip-update.sh;h=336aaf3583e16b42e527832d67ad1e414a45ac24;hb=32fb94de4f6b8e30ee53486f87721e73ed4eff50;hp=42dab1f2e67b93055daaa37fc3e83589973adfe8;hpb=ebd0ea323de3eacc11e1a624f8cc4f961d8bdb6c;p=distro-setup diff --git a/dynamic-ip-update.sh b/dynamic-ip-update.sh index 42dab1f..336aaf3 100755 --- a/dynamic-ip-update.sh +++ b/dynamic-ip-update.sh @@ -4,7 +4,7 @@ set -eE -o pipefail trap 'echo "$0:$LINENO:error: \"$BASH_COMMAND\" returned $?" >&2' ERR -cur="$(host -4 iank.life iankelling.org | sed -rn 's/.*has address (.*)/\1/p;T;q')" +cur="$(host -4 b8.nz iankelling.org | sed -rn 's/.*has address (.*)/\1/p;T;q')" ip=$(curl -s4 https://iankelling.org/cgi/pubip) # note, a simpler way to do this would be to ssh and use @@ -12,29 +12,36 @@ ip=$(curl -s4 https://iankelling.org/cgi/pubip) # to update bind if needed. if [[ $cur != $ip ]]; then - nsupdate -k /p/c/machine_specific/li/filesystem/etc/bind/Kiank.life.*.private <$f <$f <