forked from Venafi/vcert
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Jenkinsfile
58 lines (52 loc) · 1.85 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
#!/usr/bin/env groovy
node("jnode-vcert") {
String goPath = "/go/src/github.com/Venafi/vcert/v4"
stage('Checkout') {
checkout scm
}
stage("Build") {
docker.image("golang:1.9").inside("-v ${pwd()}:${goPath} -u root") {
sh "cd ${goPath} && make build"
}
}
stage("Run Tests") {
parallel(
test: {
docker.image("golang:1.9").inside("-v ${pwd()}:${goPath} -u root") {
sh "cd ${goPath} && go get ./... && make test"
}
},
e2eTPP: {
docker.image("golang:1.9").inside("-v ${pwd()}:${goPath} -u root") {
sh "cd ${goPath} && go get ./... && make tpp_test"
}
},
e2eCloud: {
docker.image("golang:1.9").inside("-v ${pwd()}:${goPath} -u root") {
sh "cd ${goPath} && go get ./... && make cloud_test"
}
},
testCLI: {
sh "make cucumber"
}
)
}
stage("Deploy") {
archiveArtifacts artifacts: 'bin/**/*', fingerprint: true
}
stage("Publish") {
cifsPublisher paramPublish: null, masterNodeName:'', alwaysPublishFromMaster: false,
continueOnError: false,
failOnError: false,
publishers: [[
configName: 'buildsDev',
transfers: [[
cleanRemote: true, excludes: '*/obj/,/node_modules/,/_src/,/_config/,/_sassdocs/',
flatten: false, makeEmptyDirs: false, noDefaultExcludes: false, patternSeparator: '[, ]+',
remoteDirectory: env.JOB_NAME, remoteDirectorySDF: false,
removePrefix: 'bin',
sourceFiles: 'bin/'
]], usePromotionTimestamp: false, useWorkspaceInPromotion: false, verbose: true
]]
}
}