That would be great. My first attempt didn't seem to work. Even some
example output defining the roles etc, would be great from the script. I
must be doing something wrong.
Cheers
On 25 Jul 2014 14:33, "Atom Powers" <[email protected]> wrote:

> The ENC can pass on any variable you wish to define and they can be used
> by Hiera.
> I haven't got around to implementing a true CMDB yet so I use a very
> simple ruby script as my ENC. It reads the hieradata/nodes/fqdn.yaml file
> for a "role" value and returns that in the output to puppet. My hiera.yaml
> hierarchy includes "hieradata/roles/%role"
> The output of the ENC is very specific, if you can't find the information
> you need to get it to work I'll find out if I can share my ENC script with
> you off-list.
>
>
> On Thu, Jul 24, 2014 at 9:23 PM, Grant Street <[email protected]>
> wrote:
>
>> Hey
>> Thanks for the reply
>>
>> I want the ENC to pass on variables or the like so that these can be used
>> by hiera to apply roles/profiles etc.
>>
>> eg
>> ENC returns a nodes software role eg role: desktop_software
>> Then hiera can load the desktop_software.yaml file to apply that software
>> role as part of it's normal hierarchy.
>>
>> Is that possible? What would it envolve?
>>
>> Grant
>>
>>
>> On Friday, July 25, 2014 1:34:10 AM UTC+10, Atom Powers wrote:
>>>
>>> Grant,
>>>
>>> You probably want to use an ENC, which will allow you to define any fact
>>> from a specified datasource.
>>> In a simple implementation I use an ENC to read the node's hiera file
>>> and output a few facts, such as a node's role/group, which are then used by
>>> hiera to define additional information for Puppet.
>>>
>>>
>>>  --
>> 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 [email protected].
>> To view this discussion on the web visit
>> https://groups.google.com/d/msgid/puppet-users/e811237c-edfc-4eb3-b19a-af4f6e182f8b%40googlegroups.com
>> <https://groups.google.com/d/msgid/puppet-users/e811237c-edfc-4eb3-b19a-af4f6e182f8b%40googlegroups.com?utm_medium=email&utm_source=footer>
>> .
>>
>> For more options, visit https://groups.google.com/d/optout.
>>
>
>
>
> --
> Perfection is just a word I use occasionally with mustard.
> --Atom Powers--
>
> --
> 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 [email protected].
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/puppet-users/CAF-H%3DO%3DfKbZcWyxwxSQwPX_YdwUi%2BuT9RLrUchOK0x2CuaA8ug%40mail.gmail.com
> <https://groups.google.com/d/msgid/puppet-users/CAF-H%3DO%3DfKbZcWyxwxSQwPX_YdwUi%2BuT9RLrUchOK0x2CuaA8ug%40mail.gmail.com?utm_medium=email&utm_source=footer>
> .
> For more options, visit https://groups.google.com/d/optout.
>

-- 
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 [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/puppet-users/CAOOavm%3Dm-W3VyvnBWeZJnCs4gfTGmyN-5Bv2zHtFL8qhjpaJcQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to