[bind/named.conf.$] Modification pour que dns.parent(s) contienne aussi ariane2.

This commit is contained in:
Pierre-Elliott Bécue 2013-02-22 18:43:23 +01:00
parent dd55245bf0
commit 0a888db293
3 changed files with 15 additions and 27 deletions

View file

@ -20,7 +20,7 @@ def forward_zone(zone,forwarders):
""" % (zone,'; '.join(forwarders))
def reverse_crans():
for net in set(config.dns.zones_reverse):
for net in set([ net for net in config.dns.zones_reverse if net not in config.NETs['multicast']]):
for zone in netv4_to_arpa(net):
forward_zone(zone, [config.dns.master] + config.dns.slaves)
@ -53,24 +53,14 @@ if has("dns-secondary-no-forward") or has("dns-secondary") or has("dns-primary")
@// zones crans
@include "/etc/bind/generated/zones_crans";
@// la tele
@zone "tv.crans.org" {
@ type slave;
@ file "/etc/bind/generated/db.tv.crans.org";
print" masters { %s; };" % config.dns.master_tv
@};
@zone "239.in-addr.arpa" {
@ type slave;
@ file "/etc/bind/generated/db.239.in-addr.arpa";
print" masters { %s; };" % config.dns.master_tv
@};
elif has("dns-tv"):
if has("dns-tv"):
@// La zone TV
@zone "tv.crans.org" {
@ type master;
@ file "/etc/bind/generated/db.tv.crans.org";
if not "tv.crans.org" in config.dns.zones_dnssec:
@ file "/etc/bind/generated/db.tv.crans.org";
else:
@ file "/etc/bind/signed/db.tv.crans.org";
@};
@zone "239.in-addr.arpa" {
@ -78,12 +68,8 @@ elif has("dns-tv"):
@ file "/etc/bind/generated/db.239.in-addr.arpa";
@};
@// reduce log verbosity on issues outside our control
@logging {
@ category lame-servers { null; };
@};
elif has("dns-recursif"):
if has("dns-recursif") and not has("dns-secondary-no-forward"):
@zone "239.in-addr.arpa" {
@ type slave;
@ file "/etc/bind/generated/db.239.in-addr.arpa";
@ -101,7 +87,9 @@ elif has("dns-forward-only"):
@zone "rbl-plus.mail-abuse.org" {
@ type forward;
@ forward only;
print" forwarders { %s ; }; " % config.dns.parent
print " forwarders { "
print " %s;" % "; \n ".join(config.dns.parents)
print " }; "
@};
@

View file

@ -16,7 +16,7 @@ def notify(ips):
if has("dns-tv"):
notify(config.dns.slaves_tv + config.dns.recursiv)
if has("dns-primary"):
notify(config.dns.slaves + [config.dns.parent])
notify(config.dns.slaves + config.dns.parents)
elif has("dns-tv"):
notify(config.dns.slaves_tv + config.dns.recursiv)

View file

@ -53,8 +53,8 @@ if has("dns-primary") or has("dns-tv"):
@ 138.231.148.0/22; // wifi
@ 10.231.136.0/24; // adm
if has("dns-primary"):
print " %s;" % ';\n '.join(config.dns.slaves + [config.dns.parent])
if has("dns-tv"):
print " %s;" % ';\n '.join(config.dns.slaves + config.dns.parents)
elif has("dns-tv"):
print " %s;" % ';\n '.join(config.dns.slaves_tv + config.dns.recursiv)
@ };
@ allow-query { any; };