1

Is there an easy way to put some kind of variables into bind9 zone files?

Lets say i have a bunch of different zone-files, and i would like to define my ip's in one config file. So that i can make something like

www A $mywebserverip

I'm allready using CNAME records for this kind of things, but this is only working for subdomains, but not for the main domain's A records.

I'm more interested in some kind of script language that would generate the zone files for me and allow a single config place for ip-logic.

Jeff
  • 423
  • 1
  • 5
  • 10

1 Answers1

1

If you keep all hostname -> IP mappings the same across zones, you can simply make all data in the zone file relative.

There are no built-in ways to script this, no.

adaptr
  • 16,576
  • 23
  • 34