Need help with integrating sonarqube on our google cicd pipeline with github repository

Hello, I need to integrate sonarqube that resides on google cloud, as soon we trigger a ci/cd pipeline the sonarqube analyze our code and generate a report.
steps:

  1. we push or make a PR on our github repo
  2. gcp cicd pipeline gets triggered
  3. sonarqube analyzes our repo and generates reports

I have tried with several solutions for this, but i am not able to make it work, either sonarqube doesn’t initializes or else if it does, i cant make it work with our github repo.

I am totally new to google cloud and sonarqube, so i may need step by step guide for the same.
Please help me solve this issue.
Thanks.

Hi,

Welcome to the community!

I don’t have a step-by-step guide to Google Cloud + SonarQube to give you. Since you’re new to both, can I suggest that you take them one at a time? Master getting SonarQube spun up in an environment you understand. Then move it to GCP.

The docs should get you started.
 
HTH,
Ann

Thankyou so much for your reply.

I somehow managed to get started with sonarqube on gcp.
What I did:

  1. used bitnami sonarqube package
  2. bitnami made it simple, and deployed a sonarqube community edition on a vm instance on google compute engine
  3. now sonarqube is deployed and i am with sonarqube, where i can login and manage sonarqube features, etc.

Now, what I want is that I need to connect to the sonarube using my cloud-build.yaml file commands.
I need sonarqube to scan my specified repo and generates results whenever my build is triggered on google cloud build.

Can you help me with that ?

Thanks.

Hi,

What’s your CI? Have you checked the docs for guidance? Have you tried using the in-product project onboarding? It should give you the CI setup…

 
Ann