- From: jfotop <
>
- To:
- Subject: [chef] Re: Re: Nested Databags
- Date: Wed, 12 Sep 2012 08:29:09 -0700 (PDT)
Thanks for your answer.
Actually, my ldap server doesn't have IP's assigned to users and it's not an
option (that's what the ldap admins told me).
Your first idea could actually be what I need, but I would have to create the
databag when I create each node. Each node name is unknown up until the moment
it's created, when the users/ips of each group are already known, so I'll look
into it and see if it works for us.
Another solution that came to mind is that, since all of these nodes will be
using the same role, I will set a few role attributes for all groups like:
set['access_groups']['group1']['user11']="ip11"
set['access_groups']['group1']['user12']="ip12"
set['access_groups']['group2']['user21']="ip21"
set['access_groups']['group2']['user22']="ip22"
set['access_groups']['group3']['user31']="ip31" and so on.
upon node creation, an attribute would be set (for example: node.ldap_group)
and any recipe would itterate over node.access_groups.#{node.ldap_group}.each
(haven't tried it yet, so I don't know if it will work.) and get either the
users (key) either their IP.
Any other ideas?
- [chef] Re: Re: Nested Databags, jfotop, 09/12/2012
Archive powered by MHonArc 2.6.16.