在CloudBees上部署SourceNotFoundException

时间:2014-03-08 10:45:27

标签: jenkins cloudbees

我正试图与CloudBees的jenkins部署一场战争。源位于CloudBbees的Git存储库中。 我可以在我的环境中使用相同的源代码生成部署战争。 在Cloudbees的Jenkins上,构建成功,但我在部署时遇到以下错误:

[INFO] --- maven-clean-plugin:2.4.1:clean (default-clean) @ mysite ---
[INFO] Deleting /scratch/jenkins/workspace/Deploy/target
[INFO] 
[INFO] --- lutece-maven-plugin:3.0.2:site-assembly (default-cli) @ mysite ---
[INFO] Assembly-site lutece-site artifact...
[INFO] Exploding webapp in /scratch/jenkins/workspace/Deploy/target/mysite-1.0.0-SNAPSHOT...
[INFO] Copying webapp files
[INFO] Local configuration directory is /home/jenkins/lutece/conf/mysite
[WARNING] Local configuration directory /home/jenkins/lutece/conf/mysite does not exist
[INFO] Building jar: /scratch/jenkins/workspace/Deploy/target/mysite.war
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 28.993s
[INFO] Finished at: Sat Mar 08 04:26:07 EST 2014
[INFO] Final Memory: 16M/202M
[INFO] ------------------------------------------------------------------------
Waiting for Jenkins to finish collecting data
[JENKINS] Archiving /scratch/jenkins/workspace/Deploy/pom.xml to fr.paris.lutece/mysite/1.0.0-SNAPSHOT/mysite-1.0.0-SNAPSHOT.pom
channel stopped
[cloudbees-deployer] Deploying as (jenkins) to the xxxx-xxxx account
[cloudbees-deployer] Deploying mysite
com.cloudbees.plugins.deployer.exceptions.DeploySourceNotFoundException: Cannot find source for mysite
    at com.cloudbees.plugins.deployer.engines.Engine.perform(Engine.java:126)
    at com.cloudbees.plugins.deployer.DeployPublisher.perform(DeployPublisher.java:103)
    at hudson.tasks.BuildStepMonitor$1.perform(BuildStepMonitor.java:20)
    at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:795)
    at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:767)
    at hudson.maven.MavenModuleSetBuild$MavenModuleSetBuildExecution.post2(MavenModuleSetBuild.java:1030)
    at hudson.model.AbstractBuild$AbstractBuildExecution.post(AbstractBuild.java:716)
    at hudson.model.Run.execute(Run.java:1690)
    at hudson.maven.MavenModuleSetBuild.run(MavenModuleSetBuild.java:519)
    at hudson.model.ResourceController.execute(ResourceController.java:88)
    at hudson.model.Executor.run(Executor.java:246)
Build step 'Deploy applications' marked build as failure
Finished: FAILURE

应用程序ID mysite存在,可在Jenkins配置中找到。 我该怎么办?

1 个答案:

答案 0 :(得分:1)

在日志中,我看不到.war文件的“存档”阶段,因此我认为你的.war没有正确打包。你在pom.xml中正确定义了吗? 另外,如果生成了.war,请检查您的工作区/目标。