Updated to use trial version of the new DSL plugin.

This commit is contained in:
Christopher Jones 2017-09-06 13:26:42 -05:00
parent 6be06388a1
commit 68b17bad46

15
Jenkinsfile vendored
View file

@ -1,7 +1,4 @@
pipeline { pipeline {
//environment {
//}
tools { tools {
maven 'Maven 3.5.0' maven 'Maven 3.5.0'
} }
@ -15,8 +12,9 @@ pipeline {
} }
} }
stage('SonarQube analysis') { stage('SonarQube Analysis') {
steps { steps {
/*
script { script {
scannerHome = tool 'SonarQube_Scanner_3.0.3.778'; scannerHome = tool 'SonarQube_Scanner_3.0.3.778';
} }
@ -25,6 +23,11 @@ pipeline {
echo "${scannerHome}" echo "${scannerHome}"
sh "${scannerHome}/bin/sonar-scanner" sh "${scannerHome}/bin/sonar-scanner"
} }
*/
sonarqubeAnalysis {
scanner = 'SonarQube_Scanner_3.0.3.778',
server = 'Staging'
}
} }
} }
@ -39,9 +42,9 @@ pipeline {
def qualityGate = waitForQualityGate() def qualityGate = waitForQualityGate()
// if the status we got back, isn't one of the logal ones, then // if the status we got back, isn't one of the logal ones, then
// we need o fail the build // we need to fail the build
if (!allowableQualityGateStatuses.contains(qualityGate.status)) { if (!allowableQualityGateStatuses.contains(qualityGate.status)) {
error "Pipeline aborted due to quality gate failure: ${qg.status}" error "Pipeline aborted due to quality gate failure: ${qualityGate.status}"
} }
} }
} }