Skip to content
This repository was archived by the owner on Nov 23, 2021. It is now read-only.
Prev Previous commit
Next Next commit
Update Jenkinsfile
  • Loading branch information
runzexia authored and soulseen committed Apr 12, 2019
commit 9994ee452216515f6bd066d92bb16e505091f168
6 changes: 4 additions & 2 deletions Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -38,8 +38,10 @@ pipeline {
stage('sonarqube analysis') {
steps {
container ('maven') {
withSonarQubeEnv('sonar') {
sh "mvn sonar:sonar -o -gs `pwd`/configuration/settings.xml -Dsonar.branch=$BRANCH_NAME -Dsonar.login=$SONAR_TOKEN_ID"
withCredentials([string(credentialsId: "$SONAR_TOKEN_ID", variable: 'SONAR_TOKEN')]) {
withSonarQubeEnv('sonar') {
sh "mvn sonar:sonar -o -gs `pwd`/configuration/settings.xml -Dsonar.branch=$BRANCH_NAME -Dsonar.login=$SONAR_TOKEN_ID"
}
}
timeout(time: 1, unit: 'HOURS') {
waitForQualityGate abortPipeline: true
Expand Down