mirror of
https://github.com/spring-projects/spring-petclinic.git
synced 2025-07-27 09:55:49 +00:00
Added the new file sonar
This commit is contained in:
parent
3dd6fd2bf2
commit
bc5161a6c2
1 changed files with 7 additions and 1 deletions
8
Jenkinsfile
vendored
8
Jenkinsfile
vendored
|
@ -18,9 +18,15 @@ pipeline {
|
||||||
sh 'export PATH="/usr/lib/jvm/java-1.17.0-openjdk-amd64/bin:$PATH" && mvn package'
|
sh 'export PATH="/usr/lib/jvm/java-1.17.0-openjdk-amd64/bin:$PATH" && mvn package'
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
stage('sonar analysis') {
|
||||||
|
steps {
|
||||||
|
withSonarQubeEnv('SONAR_TOKEN') {
|
||||||
|
sh 'mvn verify org.sonarsource.scanner.maven:sonar-maven-plugin:sonar -Dsonar.projectKey=qtsonarqube_qtsonarqube-token -Dsonar.organization=qtsonarqube'
|
||||||
|
}
|
||||||
|
}
|
||||||
stage('postbuild') {
|
stage('postbuild') {
|
||||||
steps {
|
steps {
|
||||||
archiveArtifacts artifacts: '**/target/spring-petclinic.war',
|
archiveArtifacts artifacts: '**/target/spring-petclinic-3.0.0-SNAPSHOT.jar',
|
||||||
followSymlinks: false
|
followSymlinks: false
|
||||||
junit '**/surefire-reports/TEST-*.xml'
|
junit '**/surefire-reports/TEST-*.xml'
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue