Hi,
I want to remove a zone when the domain is a subdomain. So I created the following:
It's not a problem that .co.uk domains are seen as subdomain.
I've put this in the file /usr/local/directadmin/scripts/custom/dns_create_post.sh but it runs before the line is add to /etc/named.conf. Any idea's?
Kind regards,
Rick
I want to remove a zone when the domain is a subdomain. So I created the following:
Code:
#!/bin/sh
numofo=$(grep -o "\." <<< "$DOMAIN" | wc -l)
if [ $numofo -ge 2 ]; then
sed -i '/$DOMAIN/d' /etc/named.conf
echo "action=named&value=reload" >> /usr/local/directadmin/data/task.queue
fi
exit 0;
It's not a problem that .co.uk domains are seen as subdomain.
I've put this in the file /usr/local/directadmin/scripts/custom/dns_create_post.sh but it runs before the line is add to /etc/named.conf. Any idea's?
Kind regards,
Rick