milvus/ci/jenkinsfile/notify.groovy
quicksilver 618705f617 add email notify function
Former-commit-id: 2c4a16473de125cd19c6c440d98171e190786179
2019-07-14 00:38:21 +08:00

16 lines
482 B
Groovy

def notify() {
if (!currentBuild.resultIsBetterOrEqualTo('SUCCESS')) {
// Send an email only if the build status has changed from green/unstable to red
emailext subject: '$DEFAULT_SUBJECT',
body: '$DEFAULT_CONTENT',
recipientProviders: [
[$class: 'DevelopersRecipientProvider'],
[$class: 'RequesterRecipientProvider']
],
replyTo: '$DEFAULT_REPLYTO',
to: '$DEFAULT_RECIPIENTS'
}
}
return this