I have some hiera:
"sys_gemfirexd::gemfire_users": {
"gemfirexd.user.test": { "password": "XXXXXXXXXX" }
},
I have some puppet :
$gemfire_users=hiera_hash('sys_gemfirexd::gemfire_users', undef )
if $gemfire_users == undef {
$gemfire_users_test = "undef"
}
else {
$gemfire_users_test = "ok"
}
ok, I am not particularly proud of that bit, but.. I only occasionally need to have this last bit happen.. So, if its not defined in hiera it should not actually happen in the template..
I have some template:
<% if gemfire_users_test != "undef" -%>
<% gemfire_users.each_pair do |key, val| -%>
<%= key -%>=<%= gemfire_users['password']%>
<% end -%>
<% end -%>
Which is producing:
So fare so good, I at least have it dropping the key, now I would really like to get the value of password to drop..
I am suddenly having a difficult time wrapping my head around the needed ruby to make that part happen..