Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 10 additions & 1 deletion build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -243,7 +243,16 @@ task buildElasticsearchLocalDistro(dependsOn: unzipDownloadedElasticsearchSource
ignoreExitValue true // handled in doLast
doLast {
def exitValue = executionResult.get().exitValue
assert exitValue == 0 : "Elasticsearch build failed; logs available in ${logFile.path}"
if (exitValue != 0) {
if (logFile.exists()) {
println "\n===== Elasticsearch Build Log ====="
println logFile.text
println "===== End of Build Log =====\n"
} else {
"Elasticsearch build failed and ${logFile.path} log does not exist"
}
throw new GradleException("Elasticsearch build failed, see the logs for details.")
}
assert ext.localDistroResult.isPresent() : "Elasticsearch did not produce exactly one localdistro build"
}
}
Expand Down