How to block your PR merge in SonarQube with BitBucket Cloud

Hi there,

It’s possible to prevent merge of PR in BitbucketCloud when the Quality Gate of SonarQube Server (8.7 or higher) or SonarQube Cloud is failed.

To do that you need:

Once you have that, you can configure the branching permission of your repository in BitbucketCloud by adding a check on successful builds and no failed builds and check the condition to prevent a merge with unresolved merge checks.

That’s it! If SonarQube Cloud or SonarQube Server Quality Gate fails on your PR, you will see something like this:

Cheers,

2 Likes

Hey Aurélie Boiteux-Cabourdin, can you please look at my topic here? It is related to this topic.