mirror of
https://github.com/spring-projects/spring-petclinic.git
synced 2025-07-27 01:45:49 +00:00
changes in all branches
This commit is contained in:
parent
9ecdc1111e
commit
465db44b54
1 changed files with 32 additions and 0 deletions
32
Jenkinsfile
vendored
Normal file
32
Jenkinsfile
vendored
Normal file
|
@ -0,0 +1,32 @@
|
||||||
|
pipeline {
|
||||||
|
agent { label 'Master' }
|
||||||
|
triggers { pollSCM ('* * * * *') }
|
||||||
|
stages {
|
||||||
|
stage('vcs') {
|
||||||
|
steps {
|
||||||
|
git url: 'https://github.com/spring-projects/spring-petclinic.git',
|
||||||
|
branch: 'uat'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
stage('package') {
|
||||||
|
steps {
|
||||||
|
sh 'mvn package'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
stage('post build') {
|
||||||
|
steps {
|
||||||
|
archiveArtifacts artifacts: '**/target/spring-petclinic-3.0.0-SNAPSHOT.jar',
|
||||||
|
onlyIfSuccessful: true
|
||||||
|
junit testResults: '**/surefire-reports/TEST-*.xml'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
stage('sonar analysis') {
|
||||||
|
steps {
|
||||||
|
// performing sonarqube analysis with "withSonarQubeENV(<Name of Server configured in Jenkins>)"
|
||||||
|
withSonarQubeEnv('SONAR_CLOUD') {
|
||||||
|
sh 'mvn clean verify sonar:sonar -Dsonar.login=ea06c1ce5d1ee81e35db29d8cb0de69b42c70278 -Dsonar.organization=springpetclinic-2 -Dsonar.projectKey=springpetclinic-2_bharat'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
Loading…
Reference in a new issue