On 2 April 2014 08:47, Felix Frank <[email protected]> wrote:

> Yeah, sounds about right.
>
> Pardon my prejudice, but from your description I get the feeling that
> you are not employing hiera to the height of its strengths. You want
> your hierarchy to contain *data* for your nodes. While it's possible to
> map all your resources to YAML and make heavy use of create_resources(),
> it is certainly not beneficial in all cases.
>
> I suggest at least a cursory glance at the roles/profiles pattern (or
> what I lovingly refer to as the hiera ENC) to see if it fits you better.
>

​We're actually using the roles/profiles pattern too.

However, rather than create a separate module for our custom stuff​

​which is largely going to be install a package, a config file and a
service, we're utilising the aforementioned 'system' module to prevent
module-proliferation.

Our hiera structure mirrors the roles part of the roles/profiles pattern to
enable us to customise the packages and services available for each unique
role.  Our common.yaml provides the data for our base profile.
​

> An approach that has served me well is to make my manifests as
> pseudo-intelligent as possible (allowing puppet to do the right thing
> without us copy-pasting all the time) and sprinkle in hiera lookups only
> where customization is needed or I cannot whip up a logic based on facts
> alone.
>

​It was that copy-pasting we were trying to get away from by utilising the
system module.  I also really like the fact that we've now got pretty close
to 'infrastructure as configuration data' as opposed to 'infrastructure as
code' (obviously there'll always be some custom modules required, but our
goal is to keep those to a minimum).
​


> Note that either way, you won't solve your issue of spacing out hiera
> values per your given design structure. If you rely on manifests more,
> you can get much closer to that. (If it's a sound goal at all is yet
> another good question.)
>

​Thanks for your comments; it's always good to hear other points of view.

Regards,

Matt.

-- 
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/CAKUTv3KearKAnraJ3t2yu0VU8hFPPrHL1SVy1hEkh%3D6_AFejMg%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to