Task #37
Updated by Fernando Jose Capeletto Neto over 1 year ago
Create a multi-topic branch CMSDisplay_Sonar Jenkins pipeline to trigger SonarQube code analysis == Actions == * Created https://jenkins.fernando.engineer/job/CMSDisplay_SonarQube/ * Results are published on https://sonarqube.fernando.engineer/dashboard?id=CMSDisplay * To run sonar analysis Branch: https://gitlab.com/fernando.engineer/cms/CMSDisplay/-/tree/20230408_task37_enable_sonarqube_analysis Sonar Analysis working when launch locally from VStudio : using npm rum sonar (and configuring sonar-project.properties) Reference: https://medium.com/beingcoders/setup-sonarqube-with-angular-project-in-6-minutes-57a87b3ca8c4 The result was published in https://sonarqube.fernando.engineer/dashboard?id=CMSDisplay Created a Jenkins pipeline but still failing: = Pending = * Created project https://github.com/fjcapeletto/chrome-java-node Fix permissions : /var/lib/jenkins/workspace/CMS_SonarQube/node_modules/sonar-scanner/bin/sonar-scanner: 59: exec: : Permission denied * ng test causes pipeline to build/publish docker image hang waiting to be used as docker agent in Jenkins pipeline. launch a browser, there are alternatives to fix it : * The image above is available at https://hub.docker.com/r/fjcapeletto/chrome-java-node Branch: https://gitlab.com/fernando.engineer/cms/CMSDisplay/-/tree/20230408_task37_enable_sonarqube_analysis ** https://blog.angulartraining.com/how-to-running-angular-tests-on-continuous-integration-servers-ad492219c08c ** https://medium.com/miq-tech-and-analytics/sonar-jenkins-integration-for-angular-applications-996beab67b80