I installed sonar 4 bamboo on my Bamboo instance (v 5.5.1) and configured Sonar server settings from the administration pane.
I created a SonarQube Runner task in my plan which required to create a new Executable capability in order to define sonar runner home (I specified a path on the network that can be reached by all bamboo agents).
Unfortunately, my plan is failing because sonar runner can not be found by the plugin. The problem is that it seems the path provided in the capability is not taken into account :
Unable to find executable at C:\Users\xxxxx\bamboo-agent-home\bin\bin\sonar-runner.bat. Will try to run it anyway. The system cannot find the path specified.
I tried to use a local path instead of network one but it doesn't work any better.
Is there anything i'm doing wrong ?
Thank you for your question.
Please, make sure you are specifying the correct location to Sonar executable.
Based on the path above, please notice there are two "bin" directories and, in my opinion, it is not intended to be like that. Please, notice this will vary depending on the installation directory given.
If you find this answer useful, I would kindly ask you to accept it so the same will be visible to others who might be facing the same issue you have inquired.
Thank you for your understanding.
Rafael P. Sperafico
Hello Rafael and thanks for your answer.
Actually, I never provided a path like this to sonar 4 bamboo.
I tried a network path (like "\\my_server\my_shared_folder\folder\[...]\SonarRunner2.4\") and a local path (like "d:\SonarRunner2.4\"). Actually, whatever path I specify, I always get the same error about path "C:\Users\xxxxx\bamboo-agent-home\bin\bin\sonar-runner.bat" which makes me think that the path I provide is not taken into account at all.
What do you think ?
Hello Nicolas, * could you please inform what is the correct location to "sonar-runner.bat", please? * could you please add an Script task to your plan with the following: # on Windows, please uncomment the following line by removing the hash (#) #env # on Linux, please uncomment the following line by removing the hash (#) #set * could you please inform what is the Sonar add-on you have installed in Bamboo? Could you provide me with an screenshot displaying it in Manage Add-ons in Bamboo, please? The above will display all the environment variable available to Bamboo — Kind regards, Rafael P. Sperafico Atlassian Support
I'm the author of the Sonar for Bamboo add-on. Actually I can only think of a Windows issue here. I've just created a new SonarRunner based Bamboo build by defining the home of the SonarRunner directory in the capabilities section (/opt/sonar/sonar-runner-2.4 in my example).
I'll try to setup a Bamboo instance on Windows to reproduce this and reply to this thread as soon as I have a solution.
Just wanted to keep you up-to-date about the progress on this. We plan to auto-discover SonarRunner installations based on the
SONAR_RUNNER_HOME environment variable in the future. This would make a manual definition of the path obsolete. You can track the progress of this here: https://mibexsoftware.atlassian.net/browse/SONARBOO-4.
Concerning your issue with SonarRunner on Windows: Would you mind to create a bug report at https://mibexsoftware.atlassian.net/browse/SONARBOO. I think it is better when we discuss this issue there instead on this thread.
Thanks for bringing this up.
Michael from Mibex Software
As an administrator, you could define a new executable under ‘Overview —> Server capabilities —> Add capability’...
Capability type: Executable
Type: Sonar Runner Home
Executable label: sonarrunner
Hey Community mates! Claire here from the Software Product Marketing team. We all know software development changes rapidly, and it's often tough to keep up. But from our research, we've found the h...
Connect with like-minded Atlassian users at free events near you!Find a group
Connect with like-minded Atlassian users at free events near you!
Unfortunately there are no AUG chapters near you at the moment.Start an AUG
You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs