-
Notifications
You must be signed in to change notification settings - Fork 14
dsf configure sonarqube
To use SonarQube you need to use a token to connect, and to know the results of the analysis you need a webhook. Also, you need to install and configure SonarQube in Jenkins.
To generate the user token, go to your account clicking in the left icon on the top menu bar.
Note
|
If you don’t have any account, you can use the admin/admin user/pass |
Go to security tab and generate the token.
When you execute our SonarQube scanner in our pipeline job, you need to ask SonarQube if the quality gate has been passed. To do it you need to create a webhook.
Go to administration clicking the option on the top bar menu and select the tab for Configuration.
Then search in the left menu to go to webhook section and create your webhook.
An example for Production Line:
To use SonarQube in our pipelines you need to configure Jenkins to integrate SonarQube.
First, you need to configure the scanner. Go to Manage Jenkins clicking on left menu and enter in Global Tool Configuration.
Go to SonarQube Scanner section and add a new SonarQube scanner like this.
Now you need to configure where is our SonarQube server using the user token that you create before. Go to Manage Jenkins clicking on left menu and enter in Configure System.
For example, in Production Line the server is the next:
Note
|
Remember, the token was created at the beginning of this SonarQube configuration. |
Now is time to configure your sonar in order to measure the quality of your code. To do it, please follow the official documentation about our plugins and Quality Gates and Profiles here.
This documentation is licensed under the Creative Commons License (Attribution-NoDerivatives 4.0 International).
-
cicd configuration
-
Manual configuration
-
Automatic configuration
-
-
Custom Services
-
Azure DevOps