From 9de2c6c4749ef1f8079cb7393d3f3c24b11b13a7 Mon Sep 17 00:00:00 2001 From: Loys Ollivier Date: Thu, 14 Dec 2017 11:27:41 +0100 Subject: jjb/common: if any, display lava error msg in jenkins log Do a second grep on the lava log to include lava error message if there was any. This is usefull in case a job fails. The error can be read directly out of the jenkins log. JIRA: SPEC-1178 Change-Id: Id3333df9c56dd67f5d664ae0d234e33e3300c366 Signed-off-by: Loys Ollivier --- jjb/common/include-agl-lava-jobs-submit.sh | 1 + 1 file changed, 1 insertion(+) (limited to 'jjb') diff --git a/jjb/common/include-agl-lava-jobs-submit.sh b/jjb/common/include-agl-lava-jobs-submit.sh index 217e8da9..7794d7f6 100644 --- a/jjb/common/include-agl-lava-jobs-submit.sh +++ b/jjb/common/include-agl-lava-jobs-submit.sh @@ -46,6 +46,7 @@ JOB_OUTPUT="${JOB_BASE}_output.yaml" JOB_LOG="${JOB_BASE}_output.log" curl -s -o $JOB_OUTPUT $lava_url/scheduler/job/$job_id/log_file/plain cat $JOB_OUTPUT | grep '"target",' | sed -e 's#- {"dt".*"lvl".*"msg":."##g' -e 's#"}$##g' | tee $JOB_LOG +cat $JOB_OUTPUT | grep '"error_msg":' | sed -e 's#.*"error_msg": "##g' -e 's#", ".*##g' | tee -a $JOB_LOG echo "####" echo "#### End: Output from LAVA job $job_id ####" -- cgit 1.2.3-korg