Problem running sonarqube on multi-module project with gradle


(coderaptor) #1

I am trying to analyze a multi-module project that builds with gradle. The project structure is something like this:

And so on. I have my build.gradle under modules/ (top level directory), where I have included the sonar properties, etc. Gradle build environment is fully functional. When I trigger a “gradle sonarqube” from modules/, it complains “Please provide compiled classes of your project with property”. However, according to, it should use ${sourceSets.main.output.classesDir} as default, which doesn’t seem to be happening.

This build environment is CentOS 6.x, gradle plugin version is 2.6.2, gradle version is 4.7.

What am I missing?

(Julien Henry) #3


Could you please run gradle sonarqube and look at the content of the produced file. It should contains all properties collected by the scanner for Gradle. Look if is missing for some modules.

If you prefer, you can also send the file to me (be careful, it may contains sensitive data, like sonar.login/sonar.password).