diff --git a/scripts/update_dns_bluemchen.sh b/scripts/update_dns_bluemchen.sh index 3422db8..e48e664 100755 --- a/scripts/update_dns_bluemchen.sh +++ b/scripts/update_dns_bluemchen.sh @@ -1,25 +1,25 @@ #!/bin/bash # Switch to our DNS checkout and update it cd /srv/dns/ git pull -q # Copy over our Bind configuration cp bind/* /etc/bind/ -/etc/init.d/bind9 reload +systemctl reload bind9 # Deploy our Zones now. We track the ones which have changed to trigger a DNS change for zoneToDeploy in zones/*.zone; do # Determine which zone we are updating domain=`basename $zoneToDeploy .zone` # What will the new path be? newPath="/etc/bind/master/$domain.zone" # Has the zone changed / is it new? if [[ ! -e $newPath ]] || ! cmp -s $zoneToDeploy $newPath; then # Deploy it cp $zoneToDeploy $newPath rndc reload $domain fi done