From fbecf57fe8b03692280ca38b40ef89d00c69864c Mon Sep 17 00:00:00 2001 From: Dmitry Ilyin Date: Wed, 7 May 2014 19:44:35 +0400 Subject: [PATCH] Add local puppet log file on the nodes Change-Id: I4738f2af4367ef948b0c40e1f29ef80c1637b1b4 --- mcagents/puppetd.rb | 2 ++ 1 file changed, 2 insertions(+) diff --git a/mcagents/puppetd.rb b/mcagents/puppetd.rb index 032db05e..9623c198 100644 --- a/mcagents/puppetd.rb +++ b/mcagents/puppetd.rb @@ -36,6 +36,7 @@ module MCollective def startup_hook @splaytime = @config.pluginconf["puppetd.splaytime"].to_i || 0 @lockfile = @config.pluginconf["puppetd.lockfile"] || "/tmp/puppetd.lock" + @log = @config.pluginconf["puppetd.log"] || "/var/log/puppet.log" @statefile = @config.pluginconf["puppetd.statefile"] || "/var/lib/puppet/state/state.yaml" @pidfile = @config.pluginconf["puppet.pidfile"] || "/var/run/puppet/agent.pid" @puppetd = @config.pluginconf["puppetd.puppetd"] || "/usr/sbin/daemonize -a \ @@ -181,6 +182,7 @@ module MCollective cmd << '--debug' if request[:puppet_debug] cmd << '--evaltrace' if request[:puppet_debug] + cmd << "--logdest #{@log}" if @log cmd = cmd.join(" ")