mirror of
https://github.com/spring-projects/spring-petclinic.git
synced 2025-07-19 05:55:51 +00:00
Added missing steps.
This commit is contained in:
parent
0aea718e5e
commit
71c6368f96
1 changed files with 24 additions and 19 deletions
43
Jenkinsfile
vendored
43
Jenkinsfile
vendored
|
@ -16,28 +16,33 @@ pipeline {
|
|||
}
|
||||
}
|
||||
|
||||
stage('SonarQube analysis') {
|
||||
withSonarQubeEnv('SonarQube Scanner 3.0.3.778') {
|
||||
sh 'mvn org.sonarsource.scanner.maven:sonar-maven-plugin:3.3.0.603:sonar ' +
|
||||
'-f pom.xml ' +
|
||||
'-Dsonar.projectKey=com.huettermann:all:master ' +
|
||||
'-Dsonar.login=$SONAR_UN ' +
|
||||
'-Dsonar.password=$SONAR_PW ' +
|
||||
'-Dsonar.language=java ' +
|
||||
'-Dsonar.sources=. ' +
|
||||
'-Dsonar.tests=. ' +
|
||||
'-Dsonar.test.inclusions=**/*Test*/** ' +
|
||||
'-Dsonar.exclusions=**/*Test*/**'
|
||||
}
|
||||
stage('SonarQube analysis') {
|
||||
agent any
|
||||
steps {
|
||||
withSonarQubeEnv('SonarQube Scanner 3.0.3.778') {
|
||||
sh 'mvn org.sonarsource.scanner.maven:sonar-maven-plugin:3.3.0.603:sonar ' +
|
||||
'-f pom.xml ' +
|
||||
'-Dsonar.projectKey=com.huettermann:all:master ' +
|
||||
'-Dsonar.login=$SONAR_UN ' +
|
||||
'-Dsonar.password=$SONAR_PW ' +
|
||||
'-Dsonar.language=java ' +
|
||||
'-Dsonar.sources=. ' +
|
||||
'-Dsonar.tests=. ' +
|
||||
'-Dsonar.test.inclusions=**/*Test*/** ' +
|
||||
'-Dsonar.exclusions=**/*Test*/**'
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
stage("SonarQube Quality Gate") {
|
||||
timeout(time: 1, unit: 'HOURS') {
|
||||
def qg = waitForQualityGate()
|
||||
if (qg.status != 'OK') {
|
||||
error "Pipeline aborted due to quality gate failure: ${qg.status}"
|
||||
stage("SonarQube Quality Gate") {
|
||||
steps {
|
||||
timeout(time: 1, unit: 'HOURS') {
|
||||
def qg = waitForQualityGate()
|
||||
if (qg.status != 'OK') {
|
||||
error "Pipeline aborted due to quality gate failure: ${qg.status}"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
stage('Approve for QA') {
|
||||
|
|
Loading…
Reference in a new issue