forked from LoksaiETA/Java-mvn-app2
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathJenkinsfile
More file actions
31 lines (29 loc) · 1.13 KB
/
Jenkinsfile
File metadata and controls
31 lines (29 loc) · 1.13 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
pipeline {
agent { label 'sa-javaslave' }
tools {
// Install the Maven version configured as "M3" and add it to the path.
maven "slave_maven"
}
stages {
stage('SCM Checkout') {
steps {
echo 'Checkout Src from github repo'
git 'https://github.com/LoksaiETA/Java-mvn-app2.git'
}
}
stage('Maven Build') {
steps {
echo 'Perform Maven Build'
// Run Maven on a Unix agent.
sh "mvn -Dmaven.test.failure.ignore=true clean package"
}
}
stage('Deploy to QA Server') {
steps {
script {
sshPublisher(publishers: [sshPublisherDesc(configName: 'QA_Server', transfers: [sshTransfer(cleanRemote: false, excludes: '', execCommand: '', execTimeout: 120000, flatten: false, makeEmptyDirs: false, noDefaultExcludes: false, patternSeparator: '[, ]+', remoteDirectory: '.', remoteDirectorySDF: false, removePrefix: 'target/', sourceFiles: 'target/mvn-hello-world.war')], usePromotionTimestamp: false, useWorkspaceInPromotion: false, verbose: false)])
}
}
}
}
}