To run Sonarqube analysis for a project with TFS follow the steps described below.
1. Connect the Sonarqube server as a service endpoint in Team Project. For this go to settings –> Services and click New Service Endpoint –> Generic
![image image](https://lh3.googleusercontent.com/-_aBHdjuVt8c/WErB8_1BIyI/AAAAAAAAH84/KxcpsqocHx0/image_thumb.png?imgmax=800)
2. Fill the information. Connection Name can be any name you prefer. Provide the Sonarqube URL as the Server URL. Provide Sonarqube Admin user name ad password.
![image image](https://lh3.googleusercontent.com/-m4lJxv639YQ/WErB_5cA-yI/AAAAAAAAH9A/ZMPPZB184HQ/image4_thumb.png?imgmax=800)
3. Choose a build which is building a VS application fine at the moment and add SonarQube Begin Analysis and End Analysis steps from Task catalogue. Select the SonarQube endpoint created. Provide a key, name and a version for the project.
![image image](https://lh3.googleusercontent.com/-3bBazWt1e30/WErCCQLRlWI/AAAAAAAAH9I/YiIIvTudGVo/image8_thumb.png?imgmax=800)
4. In the end analysis leave as it is nothing special needed.
![image image](https://lh3.googleusercontent.com/-heKjtuc1EiA/WErCFi4rtaI/AAAAAAAAH9Q/rkBUzHkH9QQ/image41_thumb.png?imgmax=800)
5. Queue a build and analysis will run and send information to the SonarQube server.
![image image](https://lh3.googleusercontent.com/-IiHm-2tpG-0/WErCIT5mziI/AAAAAAAAH9Y/5eyM_JCZ-ks/image17_thumb.png?imgmax=800)
6. In the SonarQube server you can see the results of the analysis.
![image image](https://lh3.googleusercontent.com/-W6vVfwBrAZM/WErCKoIA8nI/AAAAAAAAH9g/jJrD0O0tZwk/image22_thumb.png?imgmax=800)
![image image](https://lh3.googleusercontent.com/-jzLvTN6nyG0/WErCNOlulZI/AAAAAAAAH9o/Xp9Dd-kGSCk/image26_thumb.png?imgmax=800)
![image image](https://lh3.googleusercontent.com/-gVqL-6Igdpk/WErCPboSoPI/AAAAAAAAH9w/Fm_Qa4k6g6c/image30_thumb.png?imgmax=800)
![image image](https://lh3.googleusercontent.com/-e8fk3w22Lcw/WErCSjtjPQI/AAAAAAAAH94/yqgIS1i5CEA/image37_thumb.png?imgmax=800)
No comments:
Post a Comment