当我在Jenkins中运行构建时,它成功了,我也能够部署它。 但我无法在我的maven存储库私有/发布位置找到我的jar文件
https://repository-ram-cloud.forge.cloudbees.com/release/
这是Jenkins控制台输出
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
Projects to build: [MavenProject: com.uhg.jcoe:osa-common:1.0.0 @ /scratch/jenkins/workspace/osa-common build/pom.xml]
[JENKINS] Archiving /scratch/jenkins/workspace/osa-common build/pom.xml to /home/ram-cloud/hudson_home/jobs/osa-common build/modules/com.uhg.jcoe$osa-common/builds/2013-03-16_19-13-30/archive/com.uhg.jcoe/osa-common/1.0.0/osa-common-1.0.0.pom
[JENKINS] Archiving /scratch/jenkins/workspace/osa-common build/target/osa-common-1.0.0.jar to /home/ram-cloud/hudson_home/jobs/osa-common build/modules/com.uhg.jcoe$osa-common/builds/2013-03-16_19-13-30/archive/com.uhg.jcoe/osa-common/1.0.0/osa-common-1.0.0.jar
Waiting for Jenkins to finish collecting data
channel stopped
[cloudbees-deployer] Deploying as (jenkins) to the ram-cloud account
看到它已经部署到ram-cloud帐户,但我看不到它,这就是为什么我的其他项目失败,因为他们有这个jar依赖。
答案 0 :(得分:0)
评论混淆解决方案的粗略摘要是:
您需要告诉maven实际部署工件,以便它们可以在构建之间使用:
maven clean deploy
您的POM也需要正确配置 - 按照 CloudBees Private Maven Repository
答案 1 :(得分:0)
您在日志中看到的是jenkins归档构建的结果,但这只是 Jenkins功能,与maven存储库无关。要使此工件可用于其他作业,您需要配置构建后操作“部署到我的maven存储库”并选择“发布”。