All pastes #34872 Raw Edit

Something

public shellscript v1 · immutable
#34872 ·published 2005-12-25 21:52 UTC
rendered paste body
#!/bin/bash# check delay (seconds)CHECKDELAY=5CURRENTIP="$(lynx --dump checkip.dyndns.org | awk '/IP/{ print $NF; }')"logger -t ipupdater "Started. Current official IP: $CURRENTIP; Scan delay: $CHECKDELAY seconds."while sleep $CHECKDELAY; do   NEWIP="$(lynx --dump checkip.dyndns.org | awk '/IP/{ print $NF; }')"    if [ "$CURRENTIP" != "$NEWIP" ]; then       logger -t ipupdater "IP seems to have changed to $NEWIP. Calling ddclient."       CURRENTIP="$NEWIP"       echo call ddclient with proper options here   fidone