check if dns-sync is already running

This commit is contained in:
Serghey Rodin 2016-08-25 19:45:37 +03:00
commit 19cdf5f103
11 changed files with 22 additions and 56 deletions

View file

@ -28,12 +28,7 @@ is_format_valid 'user' 'domain'
is_system_enabled "$DNS_CLUSTER" 'DNS_CLUSTER'
is_object_valid 'user' 'USER' "$user"
is_object_valid 'dns' 'DOMAIN' "$domain"
if [ ! -e "$VESTA/conf/dns-cluster.conf" ]; then
check_result $E_NOTEXIST "dns-cluster.conf doesn't exist"
fi
if [ "$(ps auxf |grep -v grep |grep $BIN/$SCRIPT |wc -l)" -gt 2 ]; then
check_result $E_EXISTS "another sync process already running"
fi
is_procces_running
remote_dns_health_check