----- "Marc Zampetti" <marc.zampe...@gmail.com> wrote: > So does this mean that I need a new intermediate class for every > possible version of the package? Just relying on using the "latest" is > REALLY BAD in production. It means that I can NEVER know for sure that > when I re-build a host that it is in the EXACT state I defined it as. > You have to remember I'm operating in an an environment were we DO NOT > let Red Hat do updates whenever it wants, and Puppet is not running in > daemon mode. We only approve OS updates on a patch by patch basis, and > only apply changes when we are ready to apply them. > > Please don't tell me "that is a bad thing to do". First, I completely
You can use extlookup[1] to handle the versions for you, then you can manage it outside of your code and just control it in data. define pkg() { $version = extlookup("pkg_${name}", "present") package{$name: ensure => $version} } class apache::install { pkg{"httpd": } } That code is configurable per host/dc/country/whatever you want without changing manifest, just data. [1] http://docs.puppetlabs.com/references/2.6.1/function.html#extlookup -- 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.