Separate containerd logs in GitHub Actions' console
`::group::` groups containerd logs by default. https://docs.github.com/en/actions/using-workflows/workflow-commands-for-github-actions#grouping-log-lines Signed-off-by: Kazuyoshi Kato <katokazu@amazon.com>
This commit is contained in:
@@ -59,7 +59,17 @@ ${CMD} --test.run="${FOCUS}" --test.v \
|
||||
--containerd-bin="${CONTAINERD_BIN}" \
|
||||
--image-list="${TEST_IMAGE_LIST:-}" && test_exit_code=$? || test_exit_code=$?
|
||||
|
||||
test $test_exit_code -ne 0 && \
|
||||
cat "$REPORT_DIR/containerd.log"
|
||||
if [[ "$test_exit_code" -ne 0 ]]; then
|
||||
if [[ -e "$GITHUB_WORKSPACE" ]]; then
|
||||
mkdir -p "$GITHUB_WORKSPACE/report"
|
||||
mv "$REPORT_DIR/containerd.log" "$GITHUB_WORKSPACE/report"
|
||||
|
||||
echo ::group::containerd logs
|
||||
cat "$GITHUB_WORKSPACE/report/containerd.log"
|
||||
echo ::endgroup::
|
||||
else
|
||||
cat "$REPORT_DIR/containerd.log"
|
||||
fi
|
||||
fi
|
||||
|
||||
exit ${test_exit_code}
|
||||
|
||||
Reference in New Issue
Block a user