-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathJenkinsfile
84 lines (72 loc) · 2.13 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
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
#!groovy
import groovy.json.JsonSlurper
@Library('jenkins-scripts@develop') _
pipeline {
agent { label "linux-slave" }
options {
buildDiscarder(logRotator(numToKeepStr:'5'))
timeout(time:1, unit: 'HOURS')
timestamps()
}
environment {
TF_VAR_ARTIFACTORY_APIKEY = credentials('TF_VAR_ARTIFACTORY_APIKEY')
TF_VAR_ARTIFACTORY_URL = credentials('TF_VAR_ARTIFACTORY_URL')
TF_VAR_ARTIFACTORY = credentials('BARCO_USER')
GPG_PRIVATE_EMS_KEY_SLM = credentials('GPG_PRIVATE_EMS_SLM')
GPG_PRIVATE_NIDGR = credentials('GPG_PRIVATE_NIDGR')
GPG_PRIVATE_JONSP = credentials('GPG_PRIVATE_KEY_JONSP')
GPG_PRIVATE_KEY_SEBBI = credentials('GPG_PRIVATE_KEY_sebbi')
BIN_BARCO_COM_APIKEY = credentials('BIN_BARCO_COM_APIKEY')
EMS_SLACK_BASEURL = credentials('EMS_SLACK_BASEURL')
EMS_SLACK_AUTH_TOKEN = credentials('EMS_SLACK_AUTH_TOKEN')
EMS_SLACK_WORKSPACE = credentials('EMS_SLACK_WORKSPACE')
EMS_SLACK_CHANNEL = credentials('EMS_SLACK_CHANNEL')
ISO_GPG_KEY_PATH = credentials('EMS_ISO_GPG_PRIVATE_KEY')
}
stages {
stage ('env') {
steps {
script {
notifyStash('STARTED')
}
sh 'make -f CI-Makefile env'
}
}
stage ('package') {
steps {
sh 'make -f CI-Makefile package'
}
}
stage ('lintian') {
steps {
sh 'make -f CI-Makefile lintian'
}
}
stage ('test') {
steps {
sh 'make -f CI-Makefile test'
step([$class: "TapPublisher", testResults: "**/results/test-results/*.tap"])
}
}
stage ('publish'){
when { branch "debian/*" }
steps {
sh 'make -f CI-Makefile publish'
}
}
}
post {
always {
script{
notifyStash(currentBuild.result)
notifySlack2(currentBuild.result,
"${EMS_SLACK_BASEURL}",
"${EMS_SLACK_CHANNEL}",
"${EMS_SLACK_WORKSPACE}",
"${EMS_SLACK_AUTH_TOKEN}",
"EMS_SLACK_AUTH_TOKEN"
)
}
}
}
}