summaryrefslogtreecommitdiff
path: root/manifests/publish_dns.pp
diff options
context:
space:
mode:
authorHugo Hörnquist <hugo@lysator.liu.se>2022-02-14 19:34:47 +0100
committerHugo Hörnquist <hugo@lysator.liu.se>2022-02-14 19:45:16 +0100
commit5233b23c97da750f632ae62162e434b58ee80da9 (patch)
treeb08aa87756c585f8e8429574c94e9b4782ce7f9f /manifests/publish_dns.pp
parentUse module dns_record. (diff)
downloadprofiles-5233b23c97da750f632ae62162e434b58ee80da9.tar.gz
profiles-5233b23c97da750f632ae62162e434b58ee80da9.tar.xz
Add automatic reverse zone.
Diffstat (limited to 'manifests/publish_dns.pp')
-rw-r--r--manifests/publish_dns.pp12
1 files changed, 12 insertions, 0 deletions
diff --git a/manifests/publish_dns.pp b/manifests/publish_dns.pp
index bf5aa81..40860fa 100644
--- a/manifests/publish_dns.pp
+++ b/manifests/publish_dns.pp
@@ -8,4 +8,16 @@ class profiles::publish_dns (
value => $facts['ipaddress6'],
}
+
+ [$record, $zone] = dns_record::rev_record(
+ $facts['networking']['ip6'],
+ $facts['networking']['netmask6'])
+
+ @@dns_record { "PTR automatic ${::fqdn}":
+ type => 'PTR',
+ zone => $zone,
+ key => $record,
+ value => $::fqdn,
+ }
+
}