-
Notifications
You must be signed in to change notification settings - Fork 0
/
Jenkinsfile
50 lines (49 loc) · 1.44 KB
/
Jenkinsfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
pipeline {
agent any
options {
buildDiscarder( logRotator(numToKeepStr:'20', artifactNumToKeepStr: '1'))
disableConcurrentBuilds()
timeout(time: 1, unit: 'HOURS') // timeout on whole pipeline job
}
tools {
maven 'apache-maven-latest'
jdk 'adoptium-open-jdk-11'
}
stages {
stage('Verify GEMOC Gallery Status') {
steps {
script {
withEnv(["MAVEN_OPTS=-Xmx3000m -XshowSettings:vm -Dmaven.wagon.http.ssl.insecure=true -Dmaven.wagon.http.ssl.allowall=true -Dmaven.wagon.http.ssl.ignore.validity.dates=true"]){
sh "echo $JAVA_HOME"
sh "java -version"
sh "mvn -Dmaven.test.failure.ignore clean verify --show-version "
}
}
}
post {
always {
junit '**/target/surefire-reports/TEST-*.xml'
}
}
}
}
post {
fixed {
slackSend channel: '#ci',
color: 'good',
message: "Build fixed - ${env.JOB_NAME} ${env.BUILD_NUMBER} (<${env.BUILD_URL}|Open>) is back to normal."
}
unstable {
slackSend channel: '#ci',
failOnError:true,
color: 'warning',
message: "Build unstable - ${env.JOB_NAME} ${env.BUILD_NUMBER} (<${env.BUILD_URL}|Open>)"
}
failure {
slackSend channel: '#ci',
failOnError:true,
color: 'danger',
message: "Build failed - ${env.JOB_NAME} ${env.BUILD_NUMBER} (<${env.BUILD_URL}|Open>)"
}
}
}