mirror of
https://github.com/spring-projects/spring-petclinic.git
synced 2025-07-27 01:45:49 +00:00
Added the new trigger in jenkins file
This commit is contained in:
parent
bf55d1ab47
commit
ff9cac07ec
1 changed files with 23 additions and 0 deletions
23
jenkins-pipeline
Normal file
23
jenkins-pipeline
Normal file
|
@ -0,0 +1,23 @@
|
|||
pipeliene {
|
||||
agent { label 'any' }
|
||||
triggers { pollSCM '* * * * *' }
|
||||
stages {
|
||||
stage( 'version control sysytem') {
|
||||
steps {
|
||||
git url: 'https://github.com/spring-projects/spring-petclinic.git',
|
||||
branch: 'main'
|
||||
}
|
||||
}
|
||||
stage( 'package' ) {
|
||||
steps {
|
||||
sh: 'export PATH="/usr/lib/jvm/java-17-openjdk-amd64/bin:$PATH" && ./gradlew build',
|
||||
}
|
||||
}
|
||||
stage( 'post build' ) {
|
||||
steps {
|
||||
archiveArtifacts artifacts: '**/libs/spring-petclinic-3.0.0/jar'
|
||||
onlyIfSuccesful: true
|
||||
junit testresults: '**/test-results/test/TEST-*.xml'
|
||||
}
|
||||
}
|
||||
}
|
Loading…
Reference in a new issue