terminate gracefully if stdout goes away

This commit is contained in:
David Dollar committed 2012-06-17 21:55:28 -04:00
1 parent e5521f2cbb
commit 87f65e489c
1 file changed
+2
+2
View File
@@ -60,6 +60,8 @@ class Foreman::Engine::CLI < Foreman::Engine
$stdout.puts output $stdout.puts output
$stdout.flush $stdout.flush
end end
rescue Errno::EPIPE
terminate_gracefully
end end
def shutdown def shutdown