dns_a.conf variable

Kiekeboe100

Verified User
Joined
Apr 19, 2008
Messages
142
Location
Belgium
Hi,

I'm trying to add a DNS record depending on the reseller that created the user.

I've already successfully changed virtual_host2.conf like this:

|*if CREATOR="ipv6"|
# Creator is ipv6
DO SOME STUFF
|*endif|

But when using the same format in dns_a.conf these values don't seem to be added after creating a user.

Is there a list of variables that we can use in the different template files? And should the CREATOR variable work or not?

thanks,
Stijn
 
Hi,

thanks. This is working. I've already modified dns_ns.conf to ignore ns2 (as 2nd and 3th ns are external and the same for everyone).
I've added a false ns2 server to the reseller, and used this to add custom dns values.

It would be nicer to be able to use |CREATOR|, but this is a usable workaround, thanks.

Stijn
 
Hello,

The main reason there isn't a CREATOR is because not all zones have Users.

It's possible to create a zone at:
Admin Level -> DNS Admin -> Add Zone

and it will not be linked to a User or creator, so the variable wouldn't always be filled.
The NS1/NS2 records will always be present, so would be a better choice for checks.. but requires that the values differ per creator.

Also note that the token IS_IPV6=yes will be set if the new IP is IPv6.
But.. you'd be using dns_aaaa.conf for IPv6 IPs anyway.

John
 
Back
Top