Issue #4806 has been updated by Benedikt Köppel.

oops, sorry. Hit enter too early

Actually wanted to post this:
file-ressource: useless autorequire when ensure => absent

I have a file resource like that:
file { '/home/$user':
  owner => $user,
  ensure => $ensure
} 
with $user and $ensure filled by a define "account"

When I now set account { 'beni': ensure => absent }, puppet still generates a 
autorequire => User['beni'], even though the file /home/beni doesn't need that 
user.

A workaround is this:<pre>
file { '/home/$user':
  owner => $ensure ? {
    present => $user,
    absent => []
  }
  ensure => $ensure
}</pre>

Regards,
Benedikt
----------------------------------------
Bug #4806: file-resource: useless autorequire 
http://projects.puppetlabs.com/issues/4806

Author: Benedikt Köppel
Status: Unreviewed
Priority: Normal
Assignee: 
Category: 
Target version: 
Affected version: 
Keywords: 
Branch: 





-- 
You have received this notification because you have either subscribed to it, 
or are involved in it.
To change your notification preferences, please click here: 
http://projects.puppetlabs.com/my/account

-- 
You received this message because you are subscribed to the Google Groups 
"Puppet Bugs" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/puppet-bugs?hl=en.

Reply via email to