Skip to content

Commit 2d0ada9

Browse files
committed
(maint) Emit docker container logs
- When tearing down containers, dump their logs - Perhaps make this configurable in the future, but this should suffice for now
1 parent 9771fd7 commit 2d0ada9

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

commercial/spec/dockerfile_spec.rb

+3
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,9 @@
2121
ids = result[:stdout].chomp
2222
STDOUT.puts("Retrieved running container ids:\n#{ids}")
2323
ids.each_line do |id|
24+
STDOUT.puts("Container logs for #{id}")
25+
logs = run_command("docker logs --details --timestamps #{id}")[:stdout]
26+
STDOUT.puts(logs)
2427
STDOUT.puts("Killing container #{id}")
2528
run_command("docker container kill #{id}")
2629
end

0 commit comments

Comments
 (0)