简体   繁体   English

Jenkins无法使用Maven触发SonarQube项目分析

[英]Jenkins cannot trigger a SonarQube project analysis with Maven

I am trying to configure Jenkins+Maven+SonarQube as described in the documentation on http://docs.sonarqube.org/display/SONAR/Triggering+SonarQube+on+Jenkins+Job#TriggeringSonarQubeonJenkinsJob-TriggeringaProjectAnalysiswithMaven 我正在尝试按照http://docs.sonarqube.org/display/SONAR/Triggering+SonarQube+on+Jenkins+Job#TriggeringSonarQubeonJenkinsJob-TriggeringaProjectAnalysiswithMaven上的文档中所述配置Jenkins + Maven + SonarQube

I installed the Sonar plugin (2.1) in Jenkins (1.570) - curiously, the plugin is called Sonar and not SonarQube as described on https://wiki.jenkins-ci.org/display/JENKINS/Plugins 我在詹金斯(1.570)中安装了Sonar插件(2.1)-奇怪的是,该插件名为Sonar,而不是https://wiki.jenkins-ci.org/display/JENKINS/Plugins所述的SonarQube

I configured the plugin as described on http://docs.sonarqube.org/display/SONAR/Configuring+SonarQube+Jenkins+Plugin . 我已按照http://docs.sonarqube.org/display/SONAR/Configuring+SonarQube+Jenkins+Plugin所述配置了插件。 I did not configure sonar-runner because I will not be using that, I will trigger all my analysis with Maven. 我没有配置声纳运行器,因为我不会使用它,我将使用Maven触发所有分析。

Now if I configure a Maven job, I do not have "Sonar" as a post-build action. 现在,如果我配置了Maven作业,则没有“声纳”作为构建后的动作。 I only have "Invoke Standalone Sonar Analysis", which is a sonar-runner, which I do not want. 我只有“调用独立声纳分析”,它是声纳运行器,我不需要。

What am I missing here? 我在这里想念什么?

Concerning name of the plugin (Sonar vs SonarQube) this is because there was no release of the plugin since renaming of the project. 关于插件的名称(Sonar vs SonarQube),这是因为自从重命名项目以来就没有发布插件。

Concerning your main issue, I think your are lost in Jenkins UI (don't worry it happens all the time): 关于您的主要问题,我认为您在Jenkins UI中迷路了(不用担心它会一直发生):

  • "Post Steps" section contains a drop-down list with "Invoke standalone Sonar analysis" and indeed this is a SQ Runner step “发布步骤”部分包含一个带有“调用独立声纳分析”的下拉列表,这实际上是一个SQ Runner步骤
  • "Post-build Actions" section contains a drop-down list with "Sonar" and that is the Maven step “构建后操作”部分包含带有“声纳”的下拉列表,这是Maven步骤

暂无
暂无

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

相关问题 为什么在指定Maven目标以触发SonarQube分析后Jenkins的Maven项目工作会引发错误 - Why Jenkins job for maven project throws error after specifying maven goals to trigger SonarQube analysis 使用Jenkins对非Maven项目进行Sonarqube分析 - Sonarqube analysis for non maven projects using Jenkins 使用Jenkins的Maven聚合器对c#多模块项目进行Sonarqube StyleCop分析 - Sonarqube StyleCop analysis for c# multi-module project using Maven aggregator from Jenkins Jenkins - Maven Project - SonarQube Analysis is UNSTABLE - ERROR: Unable to create symbol table for - java.lang.IllegalArgumentException: null - Jenkins - Maven Project - SonarQube Analysis is UNSTABLE - ERROR: Unable to create symbol table for - java.lang.IllegalArgumentException: null Jenkins管道出口代码137:在声纳分析中,Maven构建失败 - Jenkins pipeline exit code 137: maven build fails at sonarqube analysis 升级到SonarQube 4.2后,Jenkins / Maven分析中的NPE - NPE in Jenkins/Maven analysis after upgrade to SonarQube 4.2 来自 maven 和 Jenkins 的 SonarQube 分析有不同的结果 - SonarQube analysis from maven and Jenkins have different results 声纳分析导致0个文件通过Jenkins在Maven项目上建立索引 - Sonar analysis causes 0 files indexed on a maven project through Jenkins 无法通过詹金斯执行简单的Maven项目 - Cannot execute a simple maven project through jenkins Sonarqube-Jenkins-maven Intergate - Sonarqube-Jenkins-maven Intergate
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM