11 lines
264 B
Bash
Executable file
11 lines
264 B
Bash
Executable file
#!/bin/bash
|
|
|
|
SERVERNAME=$1
|
|
DOMAIN=rut.sunet.se
|
|
ipv4=$(dig -t a +short $SERVERNAME)
|
|
ipv6=$(dig -t aaaa +short $SERVERNAME)
|
|
|
|
knotctl update -z $DOMAIN -n ${SERVERNAME}. -a ttl=60 -r AAAA -d $ipv6
|
|
knotctl update -z $DOMAIN -n ${SERVERNAME}. -a ttl=60 -r A -d $ipv4
|
|
|
|
|