Pages

Saturday, 20 October 2012

Configuring and Launching Sonar Analysis from Jenkins - Part[II]




Configuring Jenkins for Sonar Analysis

1. Click on New Job left menu item. Provide the job name and select “Build a free-style software project” radio button. Now on clicking OK button a screen appears that lets user configure the newly created job as shown below.



2. Provide the project name and description.



3. Set build type as 'Invoke Standalone Sonar Analysis'.



4. Either provide path to project properties file or provide project properties directly in the textarea shown below and save the configuration. (Please refer to the previous post for the sonar project properties)




5. Now run the newly created 'standalone sonar analysis build' by clicking on run icon as depicted under.



6. Once build is completed navigate to its console section to see the complete logs.



Note: If build is run successfully then SUCCESS message will be visible on the bottom of the logs as shown in the below snapshot.


7. Finally go to the sonar server to see the results of the sonar analysis launched by Jenkins CI which is also shown below.




That's it. You have successfully launched your first sonar analysis from the Jenkins CI.