Ignore short domains like co.uk, com.au, etc

This commit is contained in:
Serghey Rodin 2013-10-10 13:12:21 +03:00
commit c48560842e

View file

@ -56,6 +56,12 @@ else
# Check subdomain
sub=$(echo "$dom_alias" | cut -f1 -d . -s)
dom=$(echo "$dom_alias" | sed -e "s/^$sub.//" )
# Ignore short domains like co.uk, com.au and so on
if [ "${#dom}" -le '6' ]; then
exit
fi
if [ ! -e "$USER_DATA/dns/$dom.conf" ]; then
$BIN/v-add-dns-domain \
$user $dom $IP '' '' '' '' $restart > /dev/null