Set Job Failure Conditions
By default, a job is considered failed in case:
a process running inside the job returns a non-zero exit code,
the job has failed tests,
job containers run out of memory,
the maximum job run timeout (2 hours) or job wait timeout (1 hour) is exceeded.
You can disable the conditions using the failOn
block. The default timeout can be adjusted using timeOut
(though you cannot make it longer than 2 hours):
job("Fail after 15 min") {
gradle("build")
failOn {
testFailed { enabled = false }
nonZeroExitCode { enabled = false }
outOfMemory { enabled = false }
timeOut {
runningTimeOutInMinutes = 15
}
}
}
Last modified: 15 December 2023