mirror of
https://github.com/serghey-rodin/vesta.git
synced 2025-08-19 21:04:06 -07:00
Better soultion for DKIM DNS reloading
This commit is contained in:
parent
fbac2699a4
commit
073c0164f1
2 changed files with 2 additions and 5 deletions
|
@ -123,10 +123,7 @@ if [ ! -z "$DNS_SYSTEM" ] && [ "$dkim" = 'yes' ]; then
|
||||||
p=$(cat $USER_DATA/mail/$domain.pub|grep -v ' KEY---'|tr -d '\n')
|
p=$(cat $USER_DATA/mail/$domain.pub|grep -v ' KEY---'|tr -d '\n')
|
||||||
record='_domainkey'
|
record='_domainkey'
|
||||||
policy="\"t=y; o=~;\""
|
policy="\"t=y; o=~;\""
|
||||||
$BIN/v-add-dns-record $user $domain $record TXT "$policy"
|
$BIN/v-add-dns-record $user $domain $record TXT "$policy" '' '' 'no'
|
||||||
|
|
||||||
# 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
|
|
||||||
sleep 1
|
|
||||||
|
|
||||||
record='mail._domainkey'
|
record='mail._domainkey'
|
||||||
selector="\"k=rsa\; p=$p\""
|
selector="\"k=rsa\; p=$p\""
|
||||||
|
|
|
@ -126,7 +126,7 @@ if (!empty($_POST['ok'])) {
|
||||||
|
|
||||||
// Add DNS domain
|
// Add DNS domain
|
||||||
if (($_POST['v_dns'] == 'on') && (empty($_SESSION['error_msg']))) {
|
if (($_POST['v_dns'] == 'on') && (empty($_SESSION['error_msg']))) {
|
||||||
exec (VESTA_CMD."v-add-dns-domain ".$user." ".$v_domain." ".$v_public_ip, $output, $return_var);
|
exec (VESTA_CMD."v-add-dns-domain ".$user." ".$v_domain." ".$v_public_ip." '' '' '' '' '' '' '' '' 'no'", $output, $return_var);
|
||||||
check_return_code($return_var,$output);
|
check_return_code($return_var,$output);
|
||||||
unset($output);
|
unset($output);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue