mirror of
https://github.com/spring-projects/spring-petclinic.git
synced 2025-07-24 00:05:48 +00:00
switched from slack to email
This commit is contained in:
parent
d0a8d8d437
commit
de21ce9dfa
1 changed files with 10 additions and 26 deletions
36
Jenkinsfile
vendored
36
Jenkinsfile
vendored
|
@ -1,35 +1,14 @@
|
||||||
pipeline {
|
pipeline {
|
||||||
|
|
||||||
environment {
|
|
||||||
|
|
||||||
SLACK_CHANNEL = "#gayfuckassignment"
|
|
||||||
SLACK_TEAM_DOMAIN = "yeetus345"
|
|
||||||
SLACK_TOKEN = credentials("ilhAultZiny2Kbijeb1h6XCC")
|
|
||||||
DEPLOY_URL = "http://localhost:9090/job/spring-petclinic"
|
|
||||||
}
|
|
||||||
|
|
||||||
agent any
|
agent any
|
||||||
stages {
|
stages {
|
||||||
stage('Build') {
|
stage('Build') {
|
||||||
steps {
|
steps {
|
||||||
slackSend channel: 'notif', message: "Successful build!"
|
sh 'mvn compile'
|
||||||
sh './mvnw package'
|
|
||||||
}
|
|
||||||
post {
|
|
||||||
success {
|
|
||||||
slackSend(
|
|
||||||
teamDomain: "${env.SLACK_TEAM_DOMAIN}",
|
|
||||||
token: "${env.SLACK_TOKEN}",
|
|
||||||
channel: "${env.SLACK_CHANNEL}",
|
|
||||||
color: "good",
|
|
||||||
message: "I absolutetly hate this, but hey the build succeeded"
|
|
||||||
)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
}
|
||||||
stage('Test') {
|
stage('Test') {
|
||||||
steps {
|
steps {
|
||||||
sh './mvnw package'
|
sh 'mvn clean test'
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
stage('Package') {
|
stage('Package') {
|
||||||
|
@ -39,8 +18,13 @@ environment {
|
||||||
}
|
}
|
||||||
stage('Deploy') {
|
stage('Deploy') {
|
||||||
steps {
|
steps {
|
||||||
sh './mvnw package'
|
echo 'Deploying'
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
post {
|
||||||
|
always {
|
||||||
|
emailext body: 'Jenkins Build Passed Hurray!', recipientProviders: [[$class: 'DevelopersRecipientProvider'], [$class: 'RequesterRecipientProvider']], subject: 'Jenkins Build [Spring-Petclinic]'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
Loading…
Reference in a new issue