From: Michael Tremer Date: Mon, 12 Sep 2016 20:14:44 +0000 (+0100) Subject: unbound+DHCP: Set TTL for local leases to 1m X-Git-Tag: v2.19-core106~90 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=077ea717e035aa5fa37ce670957d3312fcaabcf1;p=ipfire-2.x.git unbound+DHCP: Set TTL for local leases to 1m Signed-off-by: Michael Tremer --- diff --git a/config/unbound/unbound-dhcp-leases-bridge b/config/unbound/unbound-dhcp-leases-bridge index 61bd5d0af7..06bff2eda2 100644 --- a/config/unbound/unbound-dhcp-leases-bridge +++ b/config/unbound/unbound-dhcp-leases-bridge @@ -30,6 +30,8 @@ import subprocess import inotify.adapters +LOCAL_TTL = 60 + def setup_logging(loglevel=logging.INFO): log = logging.getLogger("dhcp") log.setLevel(loglevel) @@ -255,10 +257,10 @@ class Lease(object): def rrset(self): return [ # Forward record - (self.fqdn, "IN A", self.ipaddr), + (self.fqdn, LOCAL_TTL, "IN A", self.ipaddr), # Reverse record - (self.ipaddr, "IN PTR", self.fqdn), + (self.ipaddr, LOCAL_TTL, "IN PTR", self.fqdn), ]