SonarQube integration in MRs: CI pipeline fails if quality gate does not pass (#391325) · Issues · GitLab.org / GitLab · GitLab

Hi,

I’m contacting you because I don’t know how to configure my Gitlab CI to stop failing when SonarQube’s quality gate does not pass. Currently, as soon as I create a MR, I have a job that runs the sonar scanner with the 3 pull request parameters (https://docs.sonarqube.org/8.9/analyzing-source-code/pull-request-analysis/#analysis-parameters). In turn, it seems that the integration between SonarQube and Gitlab “creates” a new CI job named “SonarQube” in the “external” stage, that fails when the quality gate of SonarQube doesn’t pass:
image

Ideally, I would like to find a way to configure my CI so that even if this job fails, the whole CI pipeline doesn’t fail. But as I’m not creating this job, I have no idea how I could configure it.

Do you have any advice on how I could do that?

Thanks in advance.