Please find steps below for integrating SonarQube with Azure DevOps.
Pre-requisites:
1. Make sure you install SonarQube plug-in/Add-on in VSTS (Azure DevOps) using below URL:
https://marketplace.visualstudio.com/acquisition?itemName=SonarSource.sonarqube
Once added plug-in, click on proceed to Organization..
Steps:
1. Login to Azure DevOps. Go to Azure Pipelines. Edit your pipeline
2. Click on Add tasks
3. Enter Sonar
4. Add Prepare Analysis configuration
5. move up this task.
It should be like shown below:
6. edit prepare sonar analysis configuration task
7. Click on New service connection
8. Enter name and put in sonarqube url including port number and token generated
9. Choose that name and select Integrate with Maven or Gradle
10. Edit maven task and add clean install sonar:sonar
11. Run the build, it should integrate with Sonar and should do code analysis.
Pre-requisites:
1. Make sure you install SonarQube plug-in/Add-on in VSTS (Azure DevOps) using below URL:
https://marketplace.visualstudio.com/acquisition?itemName=SonarSource.sonarqube
Once added plug-in, click on proceed to Organization..
Steps:
1. Login to Azure DevOps. Go to Azure Pipelines. Edit your pipeline
2. Click on Add tasks
4. Add Prepare Analysis configuration
5. move up this task.
It should be like shown below:
6. edit prepare sonar analysis configuration task
7. Click on New service connection
8. Enter name and put in sonarqube url including port number and token generated
9. Choose that name and select Integrate with Maven or Gradle
10. Edit maven task and add clean install sonar:sonar
11. Run the build, it should integrate with Sonar and should do code analysis.
No comments:
Post a Comment