----- Luke Bigum <luke.bi...@lmax.com> wrote: > On 18/05/12 13:46, Dan White wrote: > > Ah, Gary ! Just the brain I wish to pick ! :) > > > > Thanks for the response. It makes sense. > > However, if I perceive this properly, it would provide an All-Or-Nothing > > implementation of users. > > > > I am looking for for a way to have a master list of users in hiera and then > > realize/instantiate a group-keyed-subset of the master list on each node. > > > > “Sometimes I think the surest sign that intelligent life exists elsewhere > > in the universe is that none of it has tried to contact us.” > > Bill Waterson (Calvin& Hobbes) > > > > Why not use a define to wrap the virtualised declaration of your users, > or tried and doesn't work? Theoretically like this: > > -------------------- > define virtualise_user ($name, $uid, ...) { > @user { $name: > uid => $uid, > } > } > > $all_users = hiera_hash('users') > > create_resources('virtualise_user', $all_users) > --------------------
The original posting tried it like this: class users { $system_users = hiera('system_users') $system_groups = hiera('system_groups') create_resources("@users::mkuser",$system_users) create_resources("@users::mkgroup",$system_groups) } # class users ... and puppet screamed "could not create resource of unknown type @users::mkuser" I can certainly try that and see what happens. Thanks. “Sometimes I think the surest sign that intelligent life exists elsewhere in the universe is that none of it has tried to contact us.” Bill Waterson (Calvin & Hobbes) -- 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.