Hi, I'm new to Puppet so may be going about this completely the wrong way, or perhaps it is an selinux problem rather than a Puppet problem. I have a problem copying a file and changing the seltype. I don't think it is Nagios specific. Code is something like:
file { '/usr/sbin/nrpe': source => "puppet://$puppetserver/modules/nagios/nagios/libexec/nrpe", owner => 'root', group => 'root', notify => Service['nagios'], } exec { 'chcon': command => "/usr/bin/chcon -R -t bin_t /usr/sbin/nrpe", subscribe => File['/usr/sbin/nrpe'], } What happens is that Puppet always updates the file because the seltype appears to be wrong. This means that the exec is always called and the service is always restarted: notice: /File[/usr/sbin/nrpe]/seltype: seltype changed 'bin_t' to 'nrpe_exec_t' info: /File[/usr/sbin/nrpe]: Scheduling refresh of Exec[chcon] info: /File[/usr/sbin/nrpe]: Scheduling refresh of Service[nagios] notice: /Stage[main]/Tools::Nagios/Service[nagios]: Triggered 'refresh' from 1 events notice: /Stage[main]/Nagios/Exec[chcon]/returns: executed successfully notice: /Stage[main]/Nagios/Exec[chcon]: Triggered 'refresh' from 1 events Is there any way to get out of this loop. Nagios will not start unless the seltyp is changed. Thanks David -- You received this message because you are subscribed to the Google Groups "Puppet Users" group. To post to this group, send email to puppet-users@googlegroups.com. To unsubscribe from this group, send email to puppet-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en.