Perhaps the create_resources ( http://docs.puppetlabs.com/references/2.7.3/function.html#createresources) function is what you're looking for?
On Thu, Aug 25, 2011 at 11:32 AM, Kevin Wolf <kwol...@gmail.com> wrote: > Is it possible to create a user from a hash variable? For example, > depending on location, and other factors I need to either set a UID on a > user, and possibly set a password, and shell. If the server is in a > different location though, I don't want to set the UID, or a password. > > Is it possible to do something like: > > $myvar = { > ensure => present, > group => ''jboss', > uid => 901, > password => pwhash, > } > > user{'jboss': > $myvar > } > > This fails at the user definition. > > Kevin. > > -- > You received this message because you are subscribed to the Google Groups > "Puppet Users" group. > To view this discussion on the web visit > https://groups.google.com/d/msg/puppet-users/-/NDyrvi-evY0J. > 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. > -- Adrien Thebo adr...@puppetlabs.com -- 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.