Commit 1ee00b84 by Administrator

Update Jenkinsfile

parent 1edfc256
Pipeline #84 passed with stage
in 5 seconds
...@@ -6,4 +6,12 @@ node { ...@@ -6,4 +6,12 @@ node {
sh "${scannerHome}/bin/sonar-scanner" sh "${scannerHome}/bin/sonar-scanner"
} }
} }
stage("Quality Gate"){
timeout(1) { // Just in case something goes wrong, pipeline will be killed after a timeout
def qg = waitForQualityGate('sonar') // Reuse taskId previously collected by withSonarQubeEnv
if (qg.status != 'OK') {
error "Pipeline aborted due to quality gate failure: ${qg.status}"
}
}
}
} }
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment