简体   繁体   English

我是否需要Jenkins的声纳和声纳追踪器?

[英]Do I need sonar and sonar runner for Jenkins?

I want to set up Sonar with Jenkins. 我想和詹金斯建立声纳。 But I'm not sure if the Sonar site describes two different ways to do this or if there are two necessary steps: 但是我不确定Sonar网站是否描述了两种不同的方法来执行此操作,或者不确定是否有两个必要步骤:

As far as I understood it, it's two different ways. 据我了解,这是两种不同的方式。 If this is the case, what is the difference and what are the advantages and disadvantages (between the Sonar itself and Sonar runner)? 如果是这样的话,(Sonar本身和Sonar跑步者之间)有什么区别以及优点和缺点是什么?

If you want to analyse a project with SonarQube and Jenkins, here's what you need: 如果要使用SonarQube和Jenkins分析项目,则需要满足以下条件:

  • A SonarQube server up and running SonarQube服务器启动并运行

  • A Jenkins server up and running with the SonarQube Scanner for Jenkins installed and configure to point to your SonarQube server 安装并运行SonarQube Scanner for Jenkins的Jenkins服务器已启动并运行,并配置为指向您的SonarQube服务器

  • A job configured to run a SonarQube analysis on your project: 配置为在您的项目上运行SonarQube分析的作业:

    • Using the default and standard SonarQube Scanner (suitable for most projects) 使用默认和标准的SonarQube扫描仪(适用于大多数项目)

    • Using the SonarQube Scanner for MSBuild (for .NET solutions) 将SonarQube扫描仪用于MSBuild(用于.NET解决方案)

    • Using a post build action for Maven-based projects 对基于Maven的项目使用后期构建操作

Everything is described more in details on the SonarQube Scanner for Jenkins documentation page . 有关SonenQube Scanner for Jenkins文档页面将对所有内容进行详细介绍。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM