mirror of
https://github.com/spring-projects/spring-petclinic.git
synced 2025-07-24 00:35:49 +00:00
added params to the jenkins file
This commit is contained in:
parent
c134cb9dc4
commit
07a2b55ea9
1 changed files with 6 additions and 2 deletions
|
@ -1,15 +1,19 @@
|
|||
pipeline {
|
||||
agent { label 'JDK-11' }
|
||||
stages {
|
||||
parameters {
|
||||
string(name: 'MAVEN_GOAL', defaultValue: 'mvn package', description: 'enter maven goal')
|
||||
choice(name: 'BRANCH', choices: ['master', 'main', 'three'], description: 'select one')
|
||||
}
|
||||
stage('clone') {
|
||||
steps {
|
||||
git url: 'https://github.com/GUDAPATIVENKATESH/spring-petclinic.git',
|
||||
branch: 'main'
|
||||
branch: '${params.BRANCH}'
|
||||
}
|
||||
}
|
||||
stage('build') {
|
||||
steps {
|
||||
sh 'mvn package'
|
||||
sh '${params.MAVEN_GOAL}'
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue