Skip to content

Commit 073c016

Browse files
committed
Better soultion for DKIM DNS reloading
1 parent fbac269 commit 073c016

File tree

2 files changed

+2
-5
lines changed

2 files changed

+2
-5
lines changed

bin/v-add-mail-domain

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -123,10 +123,7 @@ if [ ! -z "$DNS_SYSTEM" ] && [ "$dkim" = 'yes' ]; then
123123
p=$(cat $USER_DATA/mail/$domain.pub|grep -v ' KEY---'|tr -d '\n')
124124
record='_domainkey'
125125
policy="\"t=y; o=~;\""
126-
$BIN/v-add-dns-record $user $domain $record TXT "$policy"
127-
128-
# Wait one second to avoid editing bind zone in the same unixtime second, because bind will not reload zone if new and last modification occur in the same unixtime second
129-
sleep 1
126+
$BIN/v-add-dns-record $user $domain $record TXT "$policy" '' '' 'no'
130127

131128
record='mail._domainkey'
132129
selector="\"k=rsa\; p=$p\""

web/add/web/index.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -126,7 +126,7 @@
126126

127127
// Add DNS domain
128128
if (($_POST['v_dns'] == 'on') && (empty($_SESSION['error_msg']))) {
129-
exec (VESTA_CMD."v-add-dns-domain ".$user." ".$v_domain." ".$v_public_ip, $output, $return_var);
129+
exec (VESTA_CMD."v-add-dns-domain ".$user." ".$v_domain." ".$v_public_ip." '' '' '' '' '' '' '' '' 'no'", $output, $return_var);
130130
check_return_code($return_var,$output);
131131
unset($output);
132132
}

0 commit comments

Comments
 (0)