Yes, I should update that.  It looks for a variable IN SCOPE that matches
the variable you've used in your hierarchy.  Let me put that in for a blog
update.



On Tue, Mar 27, 2012 at 7:47 AM, pablo <pablo.fernan...@cscs.ch> wrote:

> Hi,
>
> You are indeed absolutely right, and I am very happy about that. Thanks!!
>
> I think the confusion is coming from here: http://puppetlabs.com/blog/**
> first-look-installing-and-**using-hiera/<http://puppetlabs.com/blog/first-look-installing-and-using-hiera/>
> There it constantly says "it queries Facter", which turns out to be wrong.
>
> BR/Pablo
>
>
> On 03/25/2012 06:20 PM, Jan Ivar Beddari wrote:
>
>> On 03/24/2012 10:58 AM, Fernandez Pablo wrote:
>>
>>> Hi,
>>>
>>> That would define $primary_group as a variable, not as a fact. Indeed,
>>> what I want to do is:
>>>
>>> :backends: - puppet
>>> :hierarchy: - %{primary_group}
>>> :puppet:
>>>         :datasource: data
>>>
>>> And that requires primary_group to be a fact.
>>>
>>
>> No, that's not correct. From what I can gather, for your purposes,
>> primary_group can and should be a _variable_, not a fact. It seems there is
>> a common misconception that your hierarchy can only be facts or
>> calling_module/class. You don't even have to use the puppet backend to get
>> other variables to work.
>>
>> I've been working with hiera integration into our env and this is the
>> general pattern I'm using:
>>
>> https://gist.github.com/**2197910 <https://gist.github.com/2197910>
>>
>> At first I thought I couldn't really use hiera at all as it seemed that
>> lookup variables were only fact based. That would make it possible for any
>> compromised puppet agent to alter what facts it sent and scope around my
>> data. Ouch! (I don't want my agents to be compromised of course - anyhow I
>> have to design to limit any damage done if it does happen)
>>
>> Luckily that turned out not to be true and my integration work could
>> continue with a big smile on my face!
>>
>>
>>
> --
> 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+unsubscribe@**
> googlegroups.com <puppet-users%2bunsubscr...@googlegroups.com>.
> For more options, visit this group at http://groups.google.com/**
> group/puppet-users?hl=en<http://groups.google.com/group/puppet-users?hl=en>
> .
>
>


-- 

Gary Larizza
Professional Services Engineer
Puppet Labs

-- 
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.

Reply via email to