diff --git a/Jenkinsfile b/Jenkinsfile index 0092d25..bf037eb 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -156,13 +156,24 @@ pipeline { } withSonarQubeEnv('SonarQube') { sh '''#!/bin/bash -e + + # Ensure scanner is available and PATH includes global tools + dotnet tool update --global dotnet-sonarscanner + export PATH="$PATH:/root/.dotnet/tools" + + // dotnet sonarscanner begin \ + // /k:"${SONAR_PROJECT_KEY}" \ + // /n:"${SONAR_PROJECT_NAME}" \ + // /v:"${SONAR_PROJECT_VERSION}" \ + // /d:sonar.host.url="${SONAR_HOST_URL}" \ + // /d:sonar.login="${SONAR_AUTH_TOKEN}" \ + // /d:sonar.cs.opencover.reportsPaths="${COVERAGE_FILE}" + + dotnet sonarscanner begin \ - /k:"${SONAR_PROJECT_KEY}" \ - /n:"${SONAR_PROJECT_NAME}" \ - /v:"${SONAR_PROJECT_VERSION}" \ - /d:sonar.host.url="${SONAR_HOST_URL}" \ - /d:sonar.login="${SONAR_AUTH_TOKEN}" \ + /k:AS400API \ /d:sonar.cs.opencover.reportsPaths="${COVERAGE_FILE}" + ''' } }