James Cammarata
2010-Sep-14 16:07 UTC
[Puppet Users] Managing puppet.conf and other critical config files
Is there any built-in method for puppet to update its own configs and then restart a puppetd run should they change? One of the (few) features of cfengine I always liked was that you had your emergency configs, which allowed you to update your primary cfengine configs even if you made a mistake that hosed up your ability to run updates. It''d be nice if there was some mechanism akin to the pluginsync option that would allow you to update your core configs while just specifying the server they should be pulled from. Even if there''s no interest in a feature like this, I''d be interested in hearing how others keep there puppet.conf updated across their environments without causing problems. -- This message has been scanned for viruses and dangerous content by MailScanner, and is believed to be clean. -- 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.
Nigel Kersten
2010-Sep-14 16:15 UTC
Re: [Puppet Users] Managing puppet.conf and other critical config files
On Tue, Sep 14, 2010 at 9:07 AM, James Cammarata <jimi@sngx.net> wrote:> > Is there any built-in method for puppet to update its own configs and then > restart a puppetd run should they change? One of the (few) features of > cfengine I always liked was that you had your emergency configs, which > allowed you to update your primary cfengine configs even if you made a > mistake that hosed up your ability to run updates. > > It''d be nice if there was some mechanism akin to the pluginsync option that > would allow you to update your core configs while just specifying the > server they should be pulled from. > > Even if there''s no interest in a feature like this, I''d be interested in > hearing how others keep there puppet.conf updated across their environments > without causing problems.We manage puppet.conf as a template. I''ve often wanted something similar to your feature request, where you could signify in a puppet manifest that the whole run should simply restart at that point. You should file it :) Have you thought about maybe using the pre-run hook? We use a wrapper script that upgrades an internal metapackage before the puppet run starts, so we can always do things in that package to work around this limitation. -- nigel -- 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.
James Cammarata
2010-Sep-14 16:24 UTC
Re: [Puppet Users] Managing puppet.conf and other critical config files
> We manage puppet.conf as a template. > > I''ve often wanted something similar to your feature request, where you > could signify in a puppet manifest that the whole run should simply > restart at that point. You should file it :) > > Have you thought about maybe using the pre-run hook? We use a wrapper > script that upgrades an internal metapackage before the puppet run > starts, so we can always do things in that package to work around this > limitation.I didn''t know you could do pre-run hooks. Where''s the documentation on that? I''m currently using RIP''s concat module for our puppet configs, so we can tack on some extra stuff for puppetmasterd for the servers. It''s templated also, so we can specify the "server = " line per environment. -- This message has been scanned for viruses and dangerous content by MailScanner, and is believed to be clean. -- 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.
Nigel Kersten
2010-Sep-14 16:30 UTC
Re: [Puppet Users] Managing puppet.conf and other critical config files
On Tue, Sep 14, 2010 at 9:24 AM, James Cammarata <jimi@sngx.net> wrote:> >> We manage puppet.conf as a template. >> >> I''ve often wanted something similar to your feature request, where you >> could signify in a puppet manifest that the whole run should simply >> restart at that point. You should file it :) >> >> Have you thought about maybe using the pre-run hook? We use a wrapper >> script that upgrades an internal metapackage before the puppet run >> starts, so we can always do things in that package to work around this >> limitation. > > I didn''t know you could do pre-run hooks. Where''s the documentation on > that?nigelk$ puppetd --genconfig | grep -B4 run_command # A command to run before every agent run. If this command returns a non-zero # return code, the entire Puppet run will fail. # The default value is ''''. # prerun_command -- # A command to run after every agent run. If this command returns a non-zero # return code, the entire Puppet run will be considered to have failed, even though it might have # performed work during the normal run. # The default value is ''''. # postrun_command> > I''m currently using RIP''s concat module for our puppet configs, so we can > tack on some extra stuff for puppetmasterd for the servers. It''s templated > also, so we can specify the "server = " line per environment.We''ve taken a different approach and have an entirely separate config file and vardir for our puppetmasters.> > -- > This message has been scanned for viruses and > dangerous content by MailScanner, and is > believed to be clean. > > -- > 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. > >-- nigel -- 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.