forked from Landmark-Technologies/maven-web-application
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathJenkinsfile-ebay
33 lines (31 loc) · 1 KB
/
Jenkinsfile-ebay
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
node {
def mavenHome = tool name: 'maven3.8.2'
stage('1-CloningCode') {
git credentialsId: 'GitHub-Credentials', url: 'https://github.com/adecoker/maven-web-app'
}
stage('2-mavenBuild') {
sh "${mavenHome}/bin/mvn clean package"
}
stage('3-CodeQuality') {
sh "${mavenHome}/bin/mvn clean sonar:sonar"
}
stage('4-UploadArtifacts') {
sh "${mavenHome}/bin/mvn deploy"
}
stage('5-Deploy-UAT') {
deploy adapters: [tomcat9(credentialsId: 'tomcat9-credentials', path: '', url: 'http://13.56.164.190:8880/')], contextPath: null, war: 'target/*war'
}
stage('6-EmailNotification') {
emailext body: '''Hi Everyone ,
Please build from ebay pipeline project.
AO Coker''', subject: 'Build Status', to: 'developers'
}
stage('Approval'){
timeout(time:8, unit: 'HOURS' ) {
input message: 'Please verify and approve'
}
}
stage('prod-Deploy'){
deploy adapters: [tomcat9(credentialsId: 'tomcat9-credentials', path: '', url: 'http://13.56.164.190:8880/')], contextPath: null, war: 'target/*war'
}
}