Dynamic DNS Service
Welcome to the University of Warwick Computer Society's dynamic DNS service.
This service offers members a yourname.dyn.uwcs.co.uk and yourname.dyn.warwickcompsoc.co.uk DNS 'A' record which resolves to an IP of their choice.
Usage
Place your IP address in ~/.dyndns.txt. Your subdomain should update within a minute. Only the first line is used; subsequent lines are ignored.
Remotely updating using the HTTP interface requires the use of a shared secret, which is stored in ~/.dyndns.magic.txt. This file must be chmod 600. You can generate a magic file using the following command:
$ pwgen -n -c -s 40 1 > ~/.dyndns.magic.txt; chmod 600 ~/.dyndns.magic.txt; printf "Magic: "; cat ~/.dyndns.magic.txt
Using `wget`:
$ wget -O- -q --no-check-certificate https://dyn.uwcs.co.uk/ --post-data "user=USERNAME&magic=MAGIC" $ wget -O- -q http://dyn.uwcs.co.uk/ --post-data "user=USERNAME&magic=MAGIC"
where MAGIC is your shared secret.
You can also update to a specific IP, by adding an ip= parameter.
$ wget -O- -q --no-check-certificate https://dyn.uwcs.co.uk/ --post-data "user=username&magic=MAGIC&ip=IP" $ wget -O- -q http://dyn.uwcs.co.uk/ --post-data "user=username&magic=MAGIC&ip=IP"
Using SSH
$ ssh -q user@uwcs.co.uk "echo "\$SSH_CONNECTION" | cut -d' ' -f1 > ~/.dyndns.txt"
On the web
Automatically updating
Using cron
Edit your crontab with: crontab -e and add:
* * * * * CMD
where CMD is a wget or ssh update command from above. This will update your IP every minute. Most distributions have an /etc/cron.hourly "run-parts"-based folder too.
Under MS-Windows
Run:
schtasks /create /tn "CompSoc Dynamic DNS" /tr "\"C:\path\to\wget.exe\" -O- -q http://dyn.uwcs.co.uk/ --post-data user=USERNAME&magic=MAGIC" /sc hourly