arsh0r
arsh0r
I had to add the following in dns_nsd_add(): _debug "Running $Nsd_Command" if eval "$Nsd_Command"; then oldserial=$(grep -Eho "[0-9]{10}" "$Nsd_ZoneFile") #hopefully the serial is the only 10-digit number around newserial=$(date "+%Y%m%d%H")...
You are right. Maybe it is best to implement this in the Nsd_Command script. Otherwise it would try to change the serial multiple times it you want to issue for...
I also think there is no general approach, but in my zonefile the serial is the only 10-digit number around. I just changed it to "newserial=$(expr "$oldserial" + 1)" because...