From 8df46ca9891c79ab43065989737c8e3e904acc83 Mon Sep 17 00:00:00 2001 From: Matt Pavlovich Date: Tue, 1 Oct 2024 10:21:23 -0500 Subject: [PATCH] [NO-JIRA] Enable sonar cloud analysis --- Jenkinsfile | 3 +++ 1 file changed, 3 insertions(+) diff --git a/Jenkinsfile b/Jenkinsfile index 760bf9c6c7..d511364738 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -160,8 +160,11 @@ pipeline { stage('Quality') { when { expression { return params.sonarEnabled } } + steps { + withCredentials([string(credentialsId: 'SONARCLOUD_TOKEN', variable: 'SONAR_TOKEN')]) { sh 'echo "Running the Sonar stage"' + sh 'mvn -B -e -fae clean verify sonar:sonar -Dsonar.projectKey=apache_activemq -Dsonar.organization=apache -Dsonar.host.url=https://sonarcloud.io -Dsonar.login=${SONAR_TOKEN} -Dsurefire.rerunFailingTestsCount=3' } }