diff options
author | varac <varacanero@zeromail.org> | 2017-04-02 23:50:32 +0200 |
---|---|---|
committer | varac <varacanero@zeromail.org> | 2017-04-02 23:50:32 +0200 |
commit | 7c299b190206ac85b384706600ae05bd954b7521 (patch) | |
tree | 3844024282c6f5aa77a46a90bce91013a78d50fd | |
parent | 4e39c4ed5fb89330c86b0c50110ef37ff32c000d (diff) |
After making the module compatible with puppetlabs/concat,
subscribing to the config file failed with:
Error: Failed to apply catalog: Could not find dependency
File[/etc/unbound/unbound.conf] for Service[unbound]
at /etc/puppet/modules/unbound/manifests/service.pp:21
So we use notify now from every concat::fragment
-rw-r--r-- | manifests/forward.pp | 5 | ||||
-rw-r--r-- | manifests/init.pp | 5 | ||||
-rw-r--r-- | manifests/service.pp | 1 | ||||
-rw-r--r-- | manifests/stub.pp | 5 |
4 files changed, 9 insertions, 7 deletions
diff --git a/manifests/forward.pp b/manifests/forward.pp index 740c004..4509f81 100644 --- a/manifests/forward.pp +++ b/manifests/forward.pp @@ -25,8 +25,9 @@ define unbound::forward ( $real_settings = { forward-zone => merge($zone_name, $settings) } concat::fragment { "unbound ${title}": - target => $unbound::params::config, + target => $unbound::params::config, content => template('unbound/unbound.conf.erb'), - order => 3, + order => 3, + notify => Service[$unbound::params::service] } } diff --git a/manifests/init.pp b/manifests/init.pp index 8b1c3e5..e06207e 100644 --- a/manifests/init.pp +++ b/manifests/init.pp @@ -109,8 +109,9 @@ class unbound ( } concat::fragment { 'unbound server': - target => $unbound::params::config, + target => $unbound::params::config, content => template('unbound/unbound.conf.erb'), - order => 1, + order => 1, + notify => Service[$unbound::params::service] } } diff --git a/manifests/service.pp b/manifests/service.pp index f96f453..847aec5 100644 --- a/manifests/service.pp +++ b/manifests/service.pp @@ -17,6 +17,5 @@ class unbound::service { service { $unbound::params::service: ensure => running, hasstatus => $unbound::params::hasstatus, - subscribe => File[$unbound::params::config], } } diff --git a/manifests/stub.pp b/manifests/stub.pp index 02797fd..0845b0e 100644 --- a/manifests/stub.pp +++ b/manifests/stub.pp @@ -25,8 +25,9 @@ define unbound::stub ( $real_settings = { stub-zone => merge($zone_name, $settings) } concat::fragment { "unbound ${title}": - target => $unbound::params::config, + target => $unbound::params::config, content => template('unbound/unbound.conf.erb'), - order => 2, + order => 2, + notify => Service[$unbound::params::service] } } |