Update Jenkinsfile

This commit is contained in:
ametgud4u 2020-07-07 01:57:26 +05:30 committed by GitHub
parent 137b6866d6
commit f4c7c97b7b
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

9
Jenkinsfile vendored
View file

@ -17,10 +17,11 @@ node('master'){
sh 'mvn org.sonarsource.scanner.maven:sonar-maven-plugin:3.6.0.1398:sonar' sh 'mvn org.sonarsource.scanner.maven:sonar-maven-plugin:3.6.0.1398:sonar'
} }
stage("Quality Gate") { stage("Quality Gate"){
steps { timeout(time: 1, unit: 'HOURS') {
timeout(time: 1, unit: 'HOURS') { def qg = waitForQualityGate()
waitForQualityGate abortPipeline: true if (qg.status != 'OK') {
error "Pipeline aborted due to quality gate failure: ${qg.status}"
} }
} }
} }