forked from Covisint-Hackathon/Java-HelloWorld-Sample
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathJenkinsfile
More file actions
39 lines (34 loc) · 1.12 KB
/
Copy pathJenkinsfile
File metadata and controls
39 lines (34 loc) · 1.12 KB
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
pipeline {
agent { label 'master' }
triggers {
pollSCM 'H/1 * * * *'
}
stages {
stage ('Checkout') {
steps {
git 'https://github.com/wilfredwilly/Java-HelloWorld-Sample.git'
}
}
stage('Build') {
steps {
sh '/opt/apache-maven-3.5.3/bin/mvn clean package'
junit '**/target/surefire-reports/TEST-*.xml'
archiveArtifacts artifacts: '**/target/*.war', fingerprint: true
}
}
stage('deploy') {
steps {
pushToCloudFoundry(
target: 'api.app-cloudfoundry.com',
organization: 'techm_dev',
cloudSpace: 'dev',
credentialsId: 'b7c24062-6ea4-4876-89a1-96b3c2b430b2',
selfSigned: 'true',
manifestChoice: [ // optional... defaults to manifestFile: manifest.yml
command: 'cf push /var/lib/jenkins/workspace/wilfred/manifest.yml'
]
)
}
}
}
}