--- File[/etc/confd/templates/_etc_haproxy_ipblocks.d_hiddenparma.map.tmpl].orig
+++ File[/etc/confd/templates/_etc_haproxy_ipblocks.d_hiddenparma.map.tmpl]
+ before => File[/etc/confd/conf.d/_etc_haproxy_ipblocks.d_hiddenparma.map.toml]
+ ensure => present
+ mode => 0400
+ group => root
+ require => Package[confd]
+ owner => root
Content differences:
--- /etc/confd/templates/_etc_haproxy_ipblocks.d_hiddenparma.map.tmpl.orig
+++ /etc/confd/templates/_etc_haproxy_ipblocks.d_hiddenparma.map.tmpl
@@ -0,0 +1,6 @@
+{{- $active_scope_data := json (getv "/active-scopes/haproxy_provenance_map/active") }}
+{{- $active_scope_dir := printf "/request-haproxy-provenance-map/%s/*" $active_scope_data.value }}
+{{- range gets $active_scope_dir }}
+{{- $map := json .Value }}
+{{ $map.map }}
+{{- end }}
File[/etc/confd/conf.d/_etc_haproxy_ipblocks.d_hiddenparma.map.toml]
- Parameters differences:
--- File[/etc/confd/conf.d/_etc_haproxy_ipblocks.d_hiddenparma.map.toml].orig
+++ File[/etc/confd/conf.d/_etc_haproxy_ipblocks.d_hiddenparma.map.toml]
+ notify => Service[confd]
+ group => root
+ ensure => present
+ owner => root
- Content differences:
--- /etc/confd/conf.d/_etc_haproxy_ipblocks.d_hiddenparma.map.toml.orig
+++ /etc/confd/conf.d/_etc_haproxy_ipblocks.d_hiddenparma.map.toml
@@ -0,0 +1,18 @@
+# This file is managed by Puppet!
+# Confd config file for /etc/haproxy/ipblocks.d/hiddenparma.map
+
+[template]
+src = "_etc_haproxy_ipblocks.d_hiddenparma.map.tmpl"
+dest = "/etc/haproxy/ipblocks.d/hiddenparma.map"
+
+
+mode = "0444"
+
+keys = [
+ "/request-haproxy-provenance-map",
+ "/active-scopes",
+ ]
+
+prefix = "/conftool/v1"
+check_cmd = "/usr/local/bin/confd-lint-wrap --resource _etc_haproxy_ipblocks.d_hiddenparma.map -- /usr/local/bin/check-haproxy-map {{.src}}"
+reload_cmd = "/usr/bin/systemctl reload haproxy.service"
- Confd::File[/etc/haproxy/ipblocks.d/hiddenparma.map]
- Parameters differences:
--- Confd::File[/etc/haproxy/ipblocks.d/hiddenparma.map].orig
+++ Confd::File[/etc/haproxy/ipblocks.d/hiddenparma.map]
+ instance => main
+ ensure => present
+ relative_prefix => True
+ notify => ['Service[confd]']
+ prefix => /conftool/v1
+ before => Service[haproxy]
+ mode => 0444
+ check => /usr/local/bin/check-haproxy-map
+ reload => /usr/bin/systemctl reload haproxy.service
+ watch_keys => ['/request-haproxy-provenance-map', '/active-scopes']