The way we manage is by using multiple File paths right now , for example 

        file { "/usr/local/bin/portstats.pl":
                ensure => present,
                owner  => root,
                group  => root,
                mode   => 755,
                source => ["puppet:///cacti/$project/portstats.pl.$hostname",
                           "puppet:///cacti/$project/portstats.pl-$class",
                           "puppet:///cacti/$project/portstats.pl",
                           "puppet:///cacti/portstats.pl.$hostname",
                           "puppet:///cacti/portstats.pl",
                          ]
        }


so you can use $project + $class variable in your manifest defining nodes . 

Best is to use templates , if you can easily differentiate between configs and 
they don't differ much . 

Or you could use peinaar's external Data lookup , 
http://www.devco.net/archives/2009/08/31/complex_data_and_puppet.php  to make 
sense out of your nodes structure and filenames . 



Thanks  , 
~saurabh verma 

On 13-Dec-2010, at 9:30 AM, Josh wrote:

> Greetings,
> I'm just getting started with setting up Puppet in an environment of
> about ~15 servers, a mixture of Mac OS X servers and Ubuntu servers -
> each with different roles and obviously different versions of configs.
> 
> Before I get too carried away, I was hoping to get advice on the "rule
> of thumb" about different versions of configs.  Most of the
> documentation and examples I've seen seem to be geared more towards
> "roles" of a set of nodes, such as "http nodes, dns nodes" etc.  What
> hasn't been too clear to me is a smaller scale environment where there
> aren't multiple nodes sharing the same job.
> 
> Say I have an application installed on two of my servers and
> obviously, each server has its own version of the config files for
> that.  What is the "best practice" to manage that?  Do I define a
> class for "server1" with each thing I want to manage, and point to a
> specific file (e.g. puppet://puppet/files/server1/config.cfg  .../
> server2/config.cfg ...etc)?
> 
> Any nudge in the right direction is greatly appreciated!  Thanks.
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Puppet Users" group.
> To post to this group, send email to puppet-us...@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.
> 

-- 
You received this message because you are subscribed to the Google Groups 
"Puppet Users" group.
To post to this group, send email to puppet-us...@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