diff options
author | Markus Roberts <Markus@reality.com> | 2010-02-09 15:17:53 -0800 |
---|---|---|
committer | Markus Roberts <Markus@reality.com> | 2010-02-09 15:17:53 -0800 |
commit | 27322e5460130b854835aef56ab7076bab83a00b (patch) | |
tree | b69501ce3c7fd616880f60999ad38304a40abba2 /lib/puppet/application | |
parent | 70c71c58c1dd038d033d5fdd3fecc8f15b11fd52 (diff) | |
parent | 71653a74d91b1e6e9845b4a41249861319c0d6b0 (diff) | |
download | puppet-27322e5460130b854835aef56ab7076bab83a00b.tar.gz puppet-27322e5460130b854835aef56ab7076bab83a00b.tar.xz puppet-27322e5460130b854835aef56ab7076bab83a00b.zip |
Merge branch '0.25.x'
Conflicts:
lib/puppet/agent.rb
lib/puppet/application/puppet.rb
lib/puppet/configurer.rb
man/man5/puppet.conf.5
spec/integration/defaults.rb
spec/unit/configurer.rb
Diffstat (limited to 'lib/puppet/application')
-rw-r--r-- | lib/puppet/application/puppet.rb | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/lib/puppet/application/puppet.rb b/lib/puppet/application/puppet.rb index e4baf5d05..2f7946b3d 100644 --- a/lib/puppet/application/puppet.rb +++ b/lib/puppet/application/puppet.rb @@ -1,5 +1,6 @@ require 'puppet' require 'puppet/application' +require 'puppet/configurer' require 'puppet/network/handler' require 'puppet/network/client' @@ -124,9 +125,15 @@ Puppet::Application.new(:puppet) do catalog.retrieval_duration = Time.now - starttime + configurer = Puppet::Configurer.new + configurer.execute_prerun_command + # And apply it transaction = catalog.apply + configurer.execute_postrun_command + + status = 0 if not Puppet[:noop] and options[:detailed_exitcodes] then transaction.generate_report exit(transaction.report.exit_status) @@ -134,9 +141,7 @@ Puppet::Application.new(:puppet) do exit(0) end rescue => detail - if Puppet[:trace] - puts detail.backtrace - end + puts detail.backtrace if Puppet[:trace] if detail.is_a?(XMLRPC::FaultException) $stderr.puts detail.message else |