-
Notifications
You must be signed in to change notification settings - Fork 286
/
Jenkinsfile
35 lines (35 loc) · 855 Bytes
/
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
pipeline{
agent any
stages{
stage('github validation'){
steps{
git url: 'https://github.com/akshu20791/addressbook-cicd-project'
}
}
stage('compiling the code'){
steps{
sh 'mvn compile'
}
}
stage('testing the code'){
steps{
sh 'mvn test'
}
}
stage('qa of the code'){
steps{
sh 'mvn pmd:pmd'
}
}
stage('package'){
steps{
sh 'mvn package'
}
}
stage("deploy the project on tomcat"){
steps{
sh "sudo mv /var/lib/jenkins/workspace/mypipeline/target/addressbook.war /home/ubuntu/apache-tomcat-8.5.100/webapps/"
}
}
}
}