mirror of
https://github.com/netbox-community/netbox.git
synced 2025-07-28 03:16:25 -06:00
Autocreate A/AAAA records if PTR is given a FQDN
This commit is contained in:
parent
f873848e29
commit
d14b0ec52d
@ -524,7 +524,7 @@ class IPAddress(CreatedUpdatedModel):
|
|||||||
which_zone = None
|
which_zone = None
|
||||||
zones = dns.models.Zone.objects.all()
|
zones = dns.models.Zone.objects.all()
|
||||||
for zone in zones:
|
for zone in zones:
|
||||||
if self.ptr.endswith(zone.name):
|
if self.ptr.endswith(zone.name) or self.ptr.endswith(zone.name + '.'):
|
||||||
which_zone = zone
|
which_zone = zone
|
||||||
break
|
break
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user