Skip to content

Commit db479cb

Browse files
add slack messages to etl pipeline II
1 parent 0c5d4e4 commit db479cb

File tree

1 file changed

+11
-12
lines changed

1 file changed

+11
-12
lines changed

jenkins/etl.Jenkinsfile

Lines changed: 11 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -34,17 +34,16 @@ pipeline {
3434
}
3535
}
3636
post {
37-
always {
38-
sh '''
39-
docker stop $CUR_PROJ-$JOB_NAME-$TMP_SUFFIX || :
40-
'''
41-
}
42-
always {
43-
slackSend(
44-
channel: '#mpi-alerts',
45-
message: "Job *${env.JOB_NAME} [${env.BUILD_NUMBER}]* finished with status: *${currentBuild.currentResult}* in ${currentBuild.durationString}. \nDetails: ${env.BUILD_URL}",
46-
color: currentBuild.currentResult == 'SUCCESS' ? 'good' : (currentBuild.currentResult == 'FAILURE' ? 'danger' : 'warning')
47-
)
48-
}
37+
always {
38+
sh '''
39+
docker stop $CUR_PROJ-$JOB_NAME-$TMP_SUFFIX || :
40+
'''
41+
42+
slackSend(
43+
channel: '#mpi-alerts',
44+
message: "Job *${env.JOB_NAME} [${env.BUILD_NUMBER}]* finished with status: *${currentBuild.currentResult}* in ${currentBuild.durationString}. \nDetails: ${env.BUILD_URL}",
45+
color: currentBuild.currentResult == 'SUCCESS' ? 'good' : (currentBuild.currentResult == 'FAILURE' ? 'danger' : 'warning')
46+
)
47+
}
4948
}
5049
}

0 commit comments

Comments
 (0)