fix: enable dynamic/tsig updates

- add eyaml to hiera.yaml
- consolidate all paths into single tree
- change to new profiles::dns::client wrapper
- change to new profiles::dns::record wrapper
- change to use concat method to build zone file
This commit is contained in:
2023-11-13 22:17:59 +11:00
parent 4b0b2b1ed0
commit c996c9b7e3
11 changed files with 149 additions and 37 deletions
+23
View File
@@ -0,0 +1,23 @@
# defines the base record that will be exported
define profiles::dns::record (
String $record,
Enum[
'PTR',
'A',
'CNAME',
'MX',
'NS',
'SRV',
'TXT'
] $type,
String $value,
String $zone,
Integer $order,
Stdlib::AbsolutePath $basedir = lookup('profiles::dns::master::basedir'),
) {
@@concat::fragment { "${zone}_${name}":
target => "${basedir}/${zone}.conf",
content => "${record} IN ${type} ${value}\n",
order => $order,
}
}