bind_add_dkim_zone_master.sh: Support adding DKIM zone even if zone is not yet official responsible.
This commit is contained in:
@@ -96,6 +96,12 @@ usage() {
|
||||
-k <tsig key name>
|
||||
Name of the TSIG key used for dynamical updates.
|
||||
|
||||
-m <dns_master>
|
||||
Main Domains Master DNS Server
|
||||
|
||||
-s <dns_slave>
|
||||
Main Domains Slave DNS Server
|
||||
|
||||
-t <allow-transfer options>
|
||||
allow-transfer for zone declaration. Possible values are ip-address(es)
|
||||
or existing 'acl' defininition(s).
|
||||
@@ -290,6 +296,10 @@ while getopts hk:qt: opt ; do
|
||||
;;
|
||||
k) TSIG_KEY_NAME="$OPTARG"
|
||||
;;
|
||||
m) DNS_MASTER="$OPTARG"
|
||||
;;
|
||||
s) DNS_SLAVE="$OPTARG"
|
||||
;;
|
||||
q) verbose=true
|
||||
;;
|
||||
t) ALLOW_TRANSFER_OPTION="$OPTARG"
|
||||
@@ -430,6 +440,10 @@ fi
|
||||
# - Get DNS server
|
||||
# -
|
||||
echononl "Get responsible zone for domain '$dkim_domain'.."
|
||||
if [[ -n "${DNS_MASTER}" ]] && [[ -n "${DNS_SLAVE}" ]] ; then
|
||||
echo_skipped
|
||||
dns_server_arr=("${DNS_MASTER}" "${DNS_SLAVE}")
|
||||
else
|
||||
found=true
|
||||
zone="${dkim_domain}"
|
||||
dns_servers="$(dig +short $zone NS 2>/dev/null)"
|
||||
@@ -467,6 +481,7 @@ else
|
||||
error "No responsible zone for '$dkim_domain' found!"
|
||||
clean_up 16
|
||||
fi
|
||||
fi
|
||||
|
||||
|
||||
if ! $_zone_configuration_exists ; then
|
||||
|
||||
Reference in New Issue
Block a user