Reputation: 11
I am trying to integrate Sonar in Jenkins. Due to some bad code quality - it is giving below error.
"ERROR: Error during SonarQube Scanner execution java.lang.IllegalStateException: Project does not pass the quality gate."
I do not have permission to change the quality gate right now. I want to make the build success irrespective of quality gate result. How to do it?
Upvotes: 0
Views: 2812
Reputation: 2256
The previous answer is correct but I don't have access to the settings. Also, I didn't want to change global policies or server settings even if I had the access. Luckily I can modify the script that runs the scanner. In the begin command (whatever method you are using to execute the begin command) add the flag to skip the build breaker.
sonar.buildbreaker.skip=true
Normally it is added in the form of:
/dLsonar.buildbreaker.skip=true
Upvotes: 0
Reputation: 10564
Seems that you have installed https://github.com/SonarQubeCommunity/sonar-build-breaker So either uninstall it, either try to set sonar.buildbreaker.skip=true
. Also note that SonarQube developers do not recommend to break the build - http://www.sonarqube.org/why-you-shouldnt-use-build-breaker/
Upvotes: 4