which versions are you using (SonarQube, Scanner, Plugin, and any relevant extension):
SonarQube Developer version - 8.9 LTS
Bitbucket version: 7.19.3
what are you trying to achieve
Get 2 SonarQube icons on the Bitbucket page corresponding to 2 scans against the same project, one for mvn and second sonar-scanner against UI components
On clicking the SonarQube icon on Bitbucket page, a new window appears and the link from there to bitbucket is wrongly configured to localhost and port corresponding to internal docker network. How to fix that URL to point to sonarqube
For 1 there is no issue viewing the results directly on SonarQube since it shows as 2 different projects, but on bitbucket page the results for second scan for UI only shows up. If I run only first scan the icon correctly show the results for mvn scan. Then it gets overwritten by the UI scan which is run second.
I guess you’re talking about the Quality Gate status you can reflect back to Bitbucket Server? This seems related to monorepository analysis which is supported for PRs in Enterprise Edition($$) and above.
But outside of that narrow scope, I think it’s probably normal and expected that multiple anlayses overwrite status.
That said, you should be able to use a Project Badge from each SonarQube project to reflect both Quality Gate statuses side by side.
Thanks Ann, I will try Project Badges. Any idea on second question?
On clicking the SonarQube icon on Bitbucket page, a new window appears and the link from there to bitbucket is wrongly configured to localhost and port corresponding to internal docker network. How to fix that URL to point to sonarqube
That sounds like a configuration mistake. I would start by checking SonarQube’s Server base URL (Administration → General Settings). If that looks right, I’d check where Bitbucket thinks SonarQube is.
Get 2 SonarQube icons on the Bitbucket page corresponding to 2 scans against the same project, one for mvn and second sonar-scanner against UI components
Solution: I ended up combining it into a single scan, that scans both mvn at top level and Javascript/Typescript in the UI folder. Since the results are combined I do not need to worry about 2 icons and overwtiting.
On clicking the SonarQube icon on Bitbucket page, a new window appears and the link from there to bitbucket is wrongly configured to localhost and port corresponding to internal docker network. How to fix that URL to point to sonarqube
Solution: Ann’s suggestion worked out. I would start by checking SonarQube’s Server base URL (Administration → General Settings)