What is the best way to trigger a SonarQube scan/analysis on a Pull Request, upon Pull Request creation in BitBucket?
BitBucket server v4.14.5 hosted on prem
SonarQube server 6.6 hosted on prem
Jenkins has been used to run the scans previously; would be easiest to continue down that path.
Mibex plugin not an option as it creates a new project and that workflow isn’t acceptable to my architect.
Ideally, workflow would be:
Pull Request Workflow:
Developer creates pull request - pull request triggers SonarQube scan - scan posts results back to BitBucket.
Merge to Master Workflow:
On pull request merge to ‘master’ branch, another SonarQube scan is run against “master” to maintain baseline quality of code for ‘master’