Why does Jenkins job fail with “Server.InternalError - Deployment type not supported: zip” on CloudBees?

元气小坏坏 提交于 2019-12-11 13:48:39

问题


I am trying to deploy my Play Framework application to CloudBees, and it works fine locally when play run. After git push to a git repository, it is automatically dist and then the generated zip file deployed that unfortunately fails.

Here is the log of this issue:

[info] Packaging /scratch/jenkins/workspace/hello-play-tutorial/target/scala-2.11/hello-play-tutorial_2.11-1.0-SNAPSHOT-javadoc.jar ...
[info] Done packaging.
[info] 
[info] Your package is ready in /scratch/jenkins/workspace/hello-play-tutorial/target/universal/hello-play-tutorial-1.0-SNAPSHOT.zip
[info] 
[success] Total time: 5 s, completed Sep 8, 2014 8:07:39 AM
[cloudbees-deployer] Deploying as (jenkins) to the xxx account
[cloudbees-deployer] Deploying hello-play-tutorial
[cloudbees-deployer]   Resolved from workspace as /scratch/jenkins/workspace/hello-play-tutorial/target/universal/hello-play-tutorial-1.0-SNAPSHOT.zip
[cloudbees-deployer] Deploying via API server at https://api.cloudbees.com/api
[cloudbees-deployer] 0 MB
[cloudbees-deployer] 1 MB
[cloudbees-deployer] 3 MB
[cloudbees-deployer] 4 MB
[cloudbees-deployer] 6 MB
[cloudbees-deployer] 7 MB
[cloudbees-deployer] 9 MB
[cloudbees-deployer] 10 MB
[cloudbees-deployer] 12 MB
[cloudbees-deployer] 13 MB
[cloudbees-deployer] 15 MB
[cloudbees-deployer] 16 MB
[cloudbees-deployer] 18 MB
[cloudbees-deployer] 19 MB
[cloudbees-deployer] 21 MB
[cloudbees-deployer] 22 MB
[cloudbees-deployer] 24 MB
[cloudbees-deployer] 25 MB
[cloudbees-deployer] 27 MB
[cloudbees-deployer] 28 MB
com.cloudbees.plugins.deployer.exceptions.DeployException: remote file operation failed: /scratch/jenkins/workspace/hello-play-tutorial/target/universal/hello-play-tutorial-1.0-SNAPSHOT.zip at hudson.remoting.Channel@5c358135:24b747e7
    at com.cloudbees.plugins.deployer.engines.Engine.process(Engine.java:185)
    at com.cloudbees.plugins.deployer.engines.Engine.perform(Engine.java:119)
    at com.cloudbees.plugins.deployer.DeployPublisher.perform(DeployPublisher.java:122)
    at hudson.tasks.BuildStepMonitor$1.perform(BuildStepMonitor.java:20)
    at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:825)
    at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:797)
    at hudson.model.Build$BuildExecution.post2(Build.java:183)
    at hudson.model.AbstractBuild$AbstractBuildExecution.post(AbstractBuild.java:746)
    at hudson.model.Run.execute(Run.java:1709)
    at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43)
    at hudson.model.ResourceController.execute(ResourceController.java:88)
    at hudson.model.Executor.run(Executor.java:232)
Caused by: java.io.IOException: remote file operation failed: /scratch/jenkins/workspace/hello-play-tutorial/target/universal/hello-play-tutorial-1.0-SNAPSHOT.zip at hudson.remoting.Channel@5c358135:24b747e7
    at hudson.FilePath.act(FilePath.java:910)
    at hudson.FilePath.act(FilePath.java:887)
    at com.cloudbees.plugins.deployer.engines.Engine.process(Engine.java:179)
    ... 11 more
Caused by: hudson.remoting.ProxyException: hudson.util.IOException2: Server.InternalError - Deployment type not supported: zip
    at com.cloudbees.plugins.deployer.impl.run.RunEngineImpl$DeployFileCallable.invoke(RunEngineImpl.java:382)
    at com.cloudbees.plugins.deployer.impl.run.RunEngineImpl$DeployFileCallable.invoke(RunEngineImpl.java:289)
    at com.cloudbees.plugins.deployer.engines.Engine$FingerprintingWrapper.invoke(Engine.java:271)
    at com.cloudbees.plugins.deployer.engines.Engine$FingerprintingWrapper.invoke(Engine.java:259)
    at hudson.FilePath$FileCallableWrapper.call(FilePath.java:2462)
    at hudson.remoting.UserRequest.perform(UserRequest.java:118)
    at hudson.remoting.UserRequest.perform(UserRequest.java:48)
    at hudson.remoting.Request$2.run(Request.java:328)
    at hudson.remoting.InterceptingExecutorService$1.call(InterceptingExecutorService.java:72)
    at java.util.concurrent.FutureTask.run(FutureTask.java:262)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
    at java.lang.Thread.run(Thread.java:744)
Caused by: hudson.remoting.ProxyException: com.cloudbees.api.BeesClientException: Server.InternalError - Deployment type not supported: zip
    at com.cloudbees.api.BeesClient.readResponse(BeesClient.java:1805)
    at com.cloudbees.api.BeesClient.applicationDeployArchive(BeesClient.java:732)
    at com.cloudbees.plugins.deployer.impl.run.RunEngineImpl$DeployFileCallable.invoke(RunEngineImpl.java:374)
    ... 12 more
Build step 'Deploy applications' marked build as failure
Finished: FAILURE

This question has been previously asked but there is no working answers yet -- Error when building play framework app in cloudbees with jenkins: Deployment type not supported: zip.


回答1:


You might have to parameter your application, because, as it is now, it thinks that you are trying to deploy a .war for Tomcat, since the deployment type isn't specified anywhere.

To do so, simply type the following, with the CloudBees SDK installed:

bees app:update ACCOUNT/APPLICATION -t play2

If that doesn't work, you can try the legacy way of doing it, which was:

bees config:set -a ACCOUNT/APPLICATION containerType=play2


来源:https://stackoverflow.com/questions/15274836/why-does-jenkins-job-fail-with-server-internalerror-deployment-type-not-suppo

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!