Fixed puppet-check cron job output

Using exec doesn't flush stdout properly, use system instead.
This commit is contained in:
Ossi Salmi 2011-02-25 01:05:31 +02:00 committed by Timo Mkinen
parent 749e5013b8
commit b4148531fe

View file

@ -41,8 +41,5 @@ end
# restart
printf("puppetd dead but pid file exists on host '%s', restarting\n",
Socket.gethostname)
begin
exec("service puppet start")
rescue Errno::ENOENT
exec(puppetd)
end
system("service puppet start")
system(puppetd) if $?.exitstatus == 127