diff --git a/Jenkinsfile b/Jenkinsfile index c0d9c36..1114241 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -21,4 +21,17 @@ pipeline { } } } + post { + failure { + script { + def payload = """{ + "content": "🚨 Build Failed: ${env.JOB_NAME} #${env.BUILD_NUMBER}" + }""" + + sh """ + curl -X POST -H "Content-Type: application/json" -d '${payload}' ${env.WEBHOOK_URL} + """ + } + } + } } \ No newline at end of file