Skip to content

Commit

Permalink
fixes The most common cause is that Jenkins and runbld are configured…
Browse files Browse the repository at this point in the history
… with different working directories
  • Loading branch information
v1v committed Aug 6, 2020
1 parent f701834 commit 0395eb8
Showing 1 changed file with 13 additions and 18 deletions.
31 changes: 13 additions & 18 deletions .ci/Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -400,31 +400,26 @@ def runbld() {
catchError(buildResult: 'SUCCESS', message: 'runbld post build action failed.') {
if (stashedTestReports) {
def jobName = 'elastic+beats'
// TODO: change ansible/roles/runbld/templates/runbld.conf.j2
def where = ''
if (isPR()) {
jobName = 'elastic+beats+pull-request'
where = env.BASE_DIR
}
deleteDir()
unstashV2(name: 'source', bucket: "${JOB_GCS_BUCKET}", credentialsId: "${JOB_GCS_CREDENTIALS}")
dir("${where}") {
// Unstash the test reports
stashedTestReports.each { k, v ->
dir(k) {
unstash(v)
}
// Unstash the test reports
stashedTestReports.each { k, v ->
dir(k) {
unstash(v)
}
sh(label: 'Process JUnit reports with runbld',
script: """\
## for debugging purposes
find . -name "TEST-*.xml"
cat >./runbld-script <<EOF
echo "Processing JUnit reports with runbld..."
EOF
/usr/local/bin/runbld ./runbld-script --job-name ${jobName}
""".stripIndent()) // stripIdent() requires '''/
}
sh(label: 'Process JUnit reports with runbld',
script: """\
## for debugging purposes
find . -name "TEST-*.xml"
cat >./runbld-script <<EOF
echo "Processing JUnit reports with runbld..."
EOF
/usr/local/bin/runbld ./runbld-script --job-name ${jobName}
""".stripIndent()) // stripIdent() requires '''/
}
}
}
Expand Down

0 comments on commit 0395eb8

Please sign in to comment.