Hi all,

I've been wondering what is considered best practice when it comes to
$module_name::params classes? I see for instance the latest versions
of the apache and mysql modules from puppetlabs use static variables
which cannot be overridden:
https://github.com/puppetlabs/puppetlabs-mysql/blob/master/manifests/params.pp
https://github.com/puppetlabs/puppetlabs-apache/blob/master/manifests/params.pp

But what if I want to install apache with ssl disabled? I see a few
options, all horribly bad:
1) change the params.pp file to set $ssl = false
2) change the module to use either hiera or class parameters which
allow setting this configuration flag.
3) In the older days, we used to use a mechanism that allowed for
top-scope variables to set a module level variable. This was also
messy, but at least it worked:
https://github.com/Tribily/puppet-mariadb/blob/master/manifests/params.pp

I'd be happy to hear what 'we' consider industry standard. I'm leaning
towards class parameters for configuration variables that need to be
different from deployment to deployment.

cheers,

-- 
Walter Heck
CEO and Founder @ OlinData (http://olindata.com)
Puppet training and consulting
--
Follow @olindata on Twitter and/or 'Like' our Facebook page at
http://www.facebook.com/olindata

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