forked from devopstraininghub/BATCH9
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Jenkinsfile
30 lines (25 loc) · 803 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
pipeline {
agent any
stages {
stage('CLONE SCM STAGE') {
steps {
echo 'cloning code from Git HUB'
git branch: 'main', credentialsId: 'Githubcredentails', url: 'https://github.com/devopstraininghub/BATCH9.git'
}
}
stage('BUILD ARTIFACT STAGE') {
steps {
echo 'show the source code'
sh 'ls'
echo 'build using maven'
sh 'mvn clean install'
}
}
stage('DEPLOY TO TOMCAT STAGE') {
steps {
echo 'deploy to tomcat application server'
deploy adapters: [tomcat9(credentialsId: 'c1e3fdd8-f652-4c76-9f75-7265ae3f1865', path: '', url: 'http://54.197.21.209:8081/')], contextPath: 'FACEBOOK', war: '**/*.war'
}
}
}
}