Kenton Brede
2014-Mar-05 15:56 UTC
[Puppet Users] Possible to get just the keys out of a hiera hash?
So in hiera I've got:
users_common:
user1:
ensure: present
home: /home/user1
managehome: true
user2:
ensure: present
home: /home/user2
managehome: true
I'm using "users_common" with a create_resources in one class but
I'd like
to just pull out "user1, user2" into an array from
"users_common" for a
different class.
Is this possible?
Something like:
$users_c = hiera('users_common')
$users = "${users_c['keys']}"
notify { "${users}": }
Thanks,
--
Kent
--
You received this message because you are subscribed to the Google Groups
"Puppet Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to puppet-users+unsubscribe@googlegroups.com.
To view this discussion on the web visit
https://groups.google.com/d/msgid/puppet-users/CA%2BnSE3-yW2XYU5V7-hwKkuydGpAnHcW7bJW6XUwmMhpon%2BjDiA%40mail.gmail.com.
For more options, visit https://groups.google.com/groups/opt_out.