Skip to content

Commit c485608

Browse files
committed
Ignore short domains like co.uk, com.au, etc
1 parent 7edeb11 commit c485608

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

bin/v-add-dns-on-web-alias

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,12 @@ else
5656
# Check subdomain
5757
sub=$(echo "$dom_alias" | cut -f1 -d . -s)
5858
dom=$(echo "$dom_alias" | sed -e "s/^$sub.//" )
59+
60+
# Ignore short domains like co.uk, com.au and so on
61+
if [ "${#dom}" -le '6' ]; then
62+
exit
63+
fi
64+
5965
if [ ! -e "$USER_DATA/dns/$dom.conf" ]; then
6066
$BIN/v-add-dns-domain \
6167
$user $dom $IP '' '' '' '' $restart > /dev/null

0 commit comments

Comments
 (0)