Closed timdeluxe closed 3 years ago
This section in init.pp is also problematic in that sense:
augeas { 'enable corosync':
lens => 'Shellvars.lns',
incl => '/etc/default/corosync',
context => '/files/etc/default/corosync',
changes => [
'set START "yes"',
],
require => $corosync_package_require,
before => Service['corosync'],
}
Affected Puppet, Ruby, OS and module versions/distributions
How to reproduce (e.g Puppet code you use)
What are you seeing
Error: Could not retrieve catalog from remote server: Error 500 on SERVER: Server Error: Could not find resource 'Service[corosync]' in parameter 'notify' (file: /etc/puppetlabs/code/environments/production/modules/corosync/manifests/init.pp, line: 423) on node XXXXXXX
What behaviour did you expect instead
A clean run (no error)
Output log
see above
Any additional information you'd like to impart
The error origins in dependencies. Problem is that the service as well as secauth (where the notify comes from) are optional, so it wouldn't help to subscribe from the service instead of notifying from the file. I think the only solution is a "if" statement and having the file resources twice, one with the notify, the other without.