aboutsummaryrefslogtreecommitdiffstats
path: root/gather_data.sh
blob: ad14ac3368c0d0c429e41c5f88fa9427fef67235 (plain)
1
2
3
4
5
6
7
8
9
10
11
12

@media only all and (prefers-color-scheme: dark) {
.highlight .hll { background-color: #49483e }
.highlight .c { color: #75715e } /* Comment */
.highlight .err { color: #960050; background-color: #1e0010 } /* Error */
.highlight .k { color: #66d9ef } /* Keyword */
.highlight .l { color: #ae81ff } /* Literal */
.highlight .n { color: #f8f8f2 } /* Name */
.highlight .o { color: #f92672 } /* Operator */
.highlight .p { color: #f8f8f2 } /* Punctuation */
.highlight .ch { color: #75715e } /* Comment.Hashbang */
.highlight .cm { color: #75715e } /* Comment.Multiline */
.highlight .cp { color: #75715e } /* Comment.Preproc */
.highlight .cpf { color: #75715e } /* Comment.PreprocFile */
.highlight .c1 { color: #75715e } /* Comment.Single */
.highlight .cs { colo
#!/bin/bash
##################################################################################################
# This shell is designed to support retrieval of application debugging data in the case of
# an ETE test failure. This script, along with the gather_application_data.sh will be installed
# in /opt on each of the ONAP VMs. The gather_application_data function is designed by each
# application to gather the relevant debugging data into the current working directory
# to be zipped up and transferred to the Robot VM and ultimately, posted in the failed Jenkins
# job.
##################################################################################################

JOB_NUMBER=$2
APPLICATION=$1
if [ "$JOB_NUMBER" == '' ];then
   JOB_NUMBER=0
fi
if [ "$APPLICATION" == '' ];then
   APPLICATION='job'
fi

if [ -e /opt/gather_application_data.sh ]; then
    source /opt/gather_application_data.sh
else
    >&2 echo "${APPLICATION} No gather_application_data function"
	exit
fi


FOLDER=/tmp/gather_data/${APPLICATION}_${JOB_NUMBER}
mkdir -p $FOLDER

cd ${FOLDER}

gather_application_data

cd ../
tar --remove-files -cvzf ${APPLICATION}_${JOB_NUMBER}.tar.gz ${APPLICATION}_${JOB_NUMBER}