On Fri, 12 Mar 2010, DieterVDW wrote: > On Mar 12, 11:21 am, Patrick <kc7...@gmail.com> wrote: > Those files are downloaded and installed using apt, I just want puppet > to make sure they are owned by a certain user and group. > That's the only thing puppet needs to do.
As a workaround, instead of a recursive file resource like this: file { "/some/dir": ensure => directory, recurse => inf, owner => "someuser", group => "somegroup", require => Package["the package that created the files"], } try an exec resorce like this: exec { "fix permissions in /some/dir": command => "chown -R someuser:somegroup /some/dir", require => Package["the package that created the files"], } The exec will be much faster, but it will run every time (adding a message in the log), even if the files already have the correct ownership. To get rid of the unwanted log message at the expense of slower execution, add onlyif => "some command to check whether there's a problem", The onlyif command could use something involving "find" to print the names of bad files, and "test" to see whether find's output was empty. --apb (Alan Barrett) -- You received this message because you are subscribed to the Google Groups "Puppet Users" group. To post to this group, send email to puppet-us...@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.