On Tue, Dec 20, 2011 at 8:49 AM, Swampcritter <[email protected]> wrote:
> We are developing in-house RHEL VM provisioning (similar to Satellite/
> Spacewalk) along with a customized kickstart template, but also
> including Puppet to handle the actual configuration of the
> environment. One thing we need to see is does Puppet have a variable
> that will deploy one module only once and not check against it just in
> case the configuration file it has created has been altered or not and
> try to revert back.
>
> Example: Boot using PXEBoot w/ DHCP, build RHEL VM using custom
> kickstart configuration, create local repo file with pointers to in-
> house repository and comment out the variables to use the RHN driven
> one, download from the repo and apply the RHN/Errata updates, then
> reconfigure the rc.local to install Puppet on the reboot and apply the
> actual environment requirements (i.e. check to see if its a Apache web
> server, Oracle database, Weblogic/JBoss portal, etc).
>
> The last part is the deciding factor -- as this part of the
> requirements are quite possibly going to change via the developers
> that are actually using the environment for testing and tweaking the
> RHEL OS memory and TCP communication needs (/etc/sysctl.conf) or the
> Apache /etc/httpd/httpd.conf code. We don't want Puppet to revert back
> the code variables as these are being modified by hand and not using
> SVN or any other type of code version control at this time.
>
> Anyone know if module exclusion is possible for a "deploy once, don't
> touch again" scenario?

You can use a completely separate bootstrap environment if it's
significantly different.
# onetime
puppet agent --environment bootstrap
# later on
puppet agent --environment production

Or you can use a custom fact. Easiest way is either environment
variable or facts.d (see stdlibs).

FACTER_bootstrap=true puppet agent -t

node example {
  if $::bootstrap {
    include onetime_class
  } else {
    include normal_class
  }
}

Thanks,

Nan

-- 
You received this message because you are subscribed to the Google Groups 
"Puppet Users" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/puppet-users?hl=en.

Reply via email to