Commit 187eb782 authored by Jules Sabban's avatar Jules Sabban
Browse files

Merge branch 'Mail_sending' into 'master'

Fix email sending

See merge request !1
parents cb01a41e 7083c7e2
Pipeline #42452 failed with stages
in 23 seconds
......@@ -348,8 +348,12 @@ workflow.onComplete {
// Send the HTML e-mail
if (email_address) {
// Catch failures and try with plaintext
[ 'mail', '-s', subject, email_address ].execute() << email_txt "[$name_wf] Sent summary e-mail to $email_address (mail)"
try {
def sending = [ 'echo', '-e' , email_txt ].execute() | [ 'mail', '-s', subject, email_address ].execute()
log.debug "[$name_wf] Sent summary e-mail to $email_address (mail)"
} catch (all) {
log.error "[$name_wf] ERROR ON EMAIL SENDING TO $email_address !!"
} "$email_txt"
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment