我有一份在主计算机上运行 Maven 的 Jenkins 工作
我添加了一个后期构建步骤来运行声纳并将其指向项目的pom.xml.
问题是 Jenkins 构建运行在主服务器上,而声纳服务器运行在不同的机器上。因此,当构建完成时,Sonar 会在安装它的存储库中查找构建工件,而不是 Jenkins 运行 Maven 的主机。
除了在同一台机器上安装 Sonar 和 Jenkins 之外,还有其他解决方法吗?
更多细节:
[ERROR] Failed to execute goal on project server-api: Could not resolve dependencies for project frm:frm-server-api:jar:1.0-SNAPSHOT: Failure to find frm:frm-model:jar:1.0-SNAPSHOT in http://DIFFERENT_SERVER:7080/nexus/content/repositories/releases/ was cached in the local repository, resolution will not be reattempted until the update interval of releases has elapsed or updates are forced -> [Help 1]
这是一个与服务器或服务器DIFFERENT_SERVER无关的服务器,我们正在使用它,但不在这个项目的上下文中,所以我真的不知道它是如何到达那里的。我猜这是配置错误。更多细节:sonarJenkins
- Jenkins 作业类型是一个通用项目,而不是纯粹的 maven 作业。
- 我正在使用
sonarjenkins 插件作为构建后触发器并指定pom.xml我正在使用的。 - 我已经配置
settings.xml了MAVEN_HOME/conf所需的详细信息。