-
Notifications
You must be signed in to change notification settings - Fork 0
/
JenkinsfileDemo
45 lines (41 loc) · 1.03 KB
/
JenkinsfileDemo
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
pipeline {
agent any
stages {
stage('Fetch Code') {
steps {
git branch: 'vp-rem', url: 'https://github.com/devopshydclub/vprofile-repo.git'
}
}
stage('BUILD') {
steps {
sh 'mvn clean install -DskipTests'
}
post {
success {
echo 'Now Archiving...'
archiveArtifacts artifacts: '**/target/*.war'
}
}
}
stage('UNIT TEST') {
steps{
sh 'mvn test'
}
}
stage('INTEGRATION TEST'){
steps {
sh 'mvn verify -DskipUnitTests'
}
}
stage('CODE ANALYSIS'){
steps {
sh 'mvn checkstyle:checkstyle'
}
post {
success {
echo 'Generate Analysis Result'
}
}
}
}
}