Rudy Gevaert
2010-Jun-08 19:57 UTC
[Puppet Users] using modules from the forge (variable setting)
Dear all, I''m fairly new to puppet, so please excuse this newbie question. I was wondering how I can override a certain variable in a module I downloaded from the forge. By example. I downloaded and installed the puppetlabs-collectd module. In collectd::params there is a variable that sets the collectd server. Due to variable scope I can''t override it in my node defintion (or I must be doing something wrong). I can change the params.pp file. But is that the best way? I would expect this not to be the right way, as when I update the module I''ll have to change that again manually. Thanks for taking the time to read/respond! Rudy -- 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. For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en.
Brian
2010-Jun-09 15:42 UTC
[Puppet Users] Re: using modules from the forge (variable setting)
On Jun 8, 3:57 pm, Rudy Gevaert <rudy.geva...@gmail.com> wrote:> Dear all, > > I''m fairly new to puppet, so please excuse this newbie question. > > I was wondering how I can override a certain variable in a module I > downloaded from the forge. > > By example. I downloaded and installed the puppetlabs-collectd > module. In collectd::params there is a variable that sets the > collectd server. > > Due to variable scope I can''t override it in my node defintion (or I > must be doing something wrong). I can change the params.pp file. But > is that the best way? > > I would expect this not to be the right way, as when I update the > module I''ll have to change that again manually. > > Thanks for taking the time to read/respond!I would not consider this a newbie question. There are lots of potential approaches to building resuable modules, but the community does not appear to have settled on one. See, for instance http://www.puppetmanaged.org/documentation/Puppet_Common_Modules.html http://www.example42.com/puppet/howto.php http://plathrop.tertiusfamily.net/blog/2008/04/18/creating-puppet-modules/ http://serialized.net/2009/07/puppet-module-patterns/ Thus, the approach for customizing each module you download from the forge will vary. They will each take different amounts of work to merge updated releases with your customizations. In the case of the module you''re talking about, I think the intended approach is for you to modify params.pp. All the best, Brian Pitts -- 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. For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en.
Rudy Gevaert
2010-Jun-10 13:20 UTC
[Puppet Users] Re: using modules from the forge (variable setting)
> See, for instancehttp://www.puppetmanaged.org/documentation/Puppet_Common_Modules.htmlhttp://www.example42.com/puppet/howto.phphttp://plathrop.tertiusfamily.net/blog/2008/04/18/creating-puppet-mod...http://serialized.net/2009/07/puppet-module-patterns/ > > Thus, the approach for customizing each module you download from the > forge will vary. They will each take different amounts of work to > merge updated releases with your customizations. In the case of the > module you''re talking about, I think the intended approach is for you > to modify params.pp.Thank you for the feedback Brian! I''m surely going to have a look at the urls you included! -- 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. For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en.