-
Notifications
You must be signed in to change notification settings - Fork 22
/
openshift-release.Jenkinsfile
53 lines (48 loc) · 1.43 KB
/
openshift-release.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
51
52
53
pipeline {
agent any
environment {
OPENSHIFT_VM_IP = credentials("OPENSHIFT_VM")
OPENSHIFT_VM_PSW = credentials("OPENSHIFT_CREDS_PSW")
GITHUB_CREDS_PSW = credentials("GITHUB_TOKEN")
WAVEFRONT_TOKEN = credentials('WAVEFRONT_TOKEN_NIMBA')
}
stages {
stage("Setup Tools") {
steps {
sh './wavefront/release/setup-for-release.sh'
}
}
stage("Openshift Build Report") {
options {
timeout(time: 30, unit: 'MINUTES')
}
steps {
sh './wavefront/openshift/openshift-build-report.sh'
}
}
stage("Create Helm Release PR") {
steps {
sh './wavefront/openshift/openshift-release.sh'
}
}
}
post {
// Notify only on null->failure or success->failure or failure->success
failure {
script {
if(currentBuild.previousBuild == null) {
slackSend (channel: '#tobs-k8po-team', color: '#FF0000', message: "OPENSHIFT RELEASE JOB FAILED: <${env.BUILD_URL}|${env.JOB_NAME} [${env.BUILD_NUMBER}]>")
}
}
}
regression {
slackSend (channel: '#tobs-k8po-team', color: '#FF0000', message: "OPENSHIFT RELEASE JOB FAILED: <${env.BUILD_URL}|${env.JOB_NAME} [${env.BUILD_NUMBER}]>")
}
fixed {
slackSend (channel: '#tobs-k8po-team', color: '#008000', message: "OPENSHIFT RELEASE JOB FIXED: <${env.BUILD_URL}|${env.JOB_NAME} [${env.BUILD_NUMBER}]>")
}
always {
cleanWs()
}
}
}