Hello,

> I can find no good way in puppet to create these sorts of
> hierarchies.

I use a parser function that reads data from a CSV, you can make it read from a 
database or whatever.

http://nephilim.ml.org/~rip/puppet/extlookup.rb

Using this you can model all sorts of complex data structures and provide many 
levels of overrides.

something as simple as: 

$ntp_master = extlookup("ntp_master")

could allow for setting a specific value per host, per domains, per country, 
per vlan or any variable/fact combination available in your manifests and allow 
for setting sane defaults - or just produce parser errors if no data is 
available.




> 
> If I defined base nodes and try to inherit values- puppet is
> declarative so later values do not get imported.
> 
> If I define classes for global, then site, then system and try to do
> something like:
> 
> node ntpserver {
>   $ntp_master = "accurate.example.com"
>   include site::nyresearch
>   include site::global
> }
> 
> None of the values set in nyresearch will be available to classes in
> global because of scoping rules.
> 
> How are folks making this work? Have I completely missed a totally
> awesome feature or language keyword  somewhere along the line? Are
> there fun tricks with inheritance that I am missing?
> 
> Explanations or links to good docs would be greatly appreciate.
> 
> If I'm trying to go about this all wrong and someone can explain the
> error of my ways, that too would be appreciated.
> 
> -Don
> 
-- 
R.I.Pienaar

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