gpt4 book ai didi

java - OpenShift:无法在 Wildfly 上部署二进制应用程序

转载 作者:太空宇宙 更新时间:2023-11-04 06:39:38 28 4
gpt4 key购买 nike

我做了什么?
创建application

rhc app create map https://cartreflect-claytondev.rhcloud.com/reflect?github=openshift-cartridges/openshift-wildfly-cartridge  

将其配置为 binary部署

 rhc app configure -a <your application's name> --deployment-type binary  

然后我就这么做了

mkdir binary-deployment && cd binary-deployment/ && mkdir -p build-dependencies/.m2 repo/deployments dependencies/jbosseap/deployments  

复制的war文件

cp ~/code/IdeaProjects/others/tweetstream/target/tweetstream.war repo/deployments  

创建tar.gz

tar -zcvf tweetstream-archive.tar.gz binary-deployment  

可以看作

drwxr-xr-x   5 harith  Y\Domain Users      170 Jul 20 18:26 binary-deployment
-rw-r--r-- 1 harith Y\Domain Users 6124729 Jul 20 18:27 tweetstream-archive.tar.gz

现在当我部署它时,我看到

Deployment of file '/Users/harith/Downloads/tmp/tweetstream-archive.tar.gz' in progress for application map ...
Starting deploy for binary artifact
Stopping gear
Stopping wildfly cart
Creating new deployment directory
Preparing deployment
Preparing build for deployment
/bin/tar: Ignoring unknown extended header keyword `SCHILY.dev'
/bin/tar: Ignoring unknown extended header keyword `SCHILY.ino'
/bin/tar: Ignoring unknown extended header keyword `SCHILY.nlink'
/bin/tar: Ignoring unknown extended header keyword `SCHILY.dev'
/bin/tar: Ignoring unknown extended header keyword `SCHILY.ino'
/bin/tar: Ignoring unknown extended header keyword `SCHILY.nlink'
/bin/tar: Ignoring unknown extended header keyword `SCHILY.dev'
/bin/tar: Ignoring unknown extended header keyword `SCHILY.ino'
/bin/tar: Ignoring unknown extended header keyword `SCHILY.nlink'
/bin/tar: Ignoring unknown extended header keyword `SCHILY.dev'
/bin/tar: Ignoring unknown extended header keyword `SCHILY.ino'
/bin/tar: Ignoring unknown extended header keyword `SCHILY.nlink'
/bin/tar: Ignoring unknown extended header keyword `LIBARCHIVE.creationtime'
/bin/tar: Ignoring unknown extended header keyword `SCHILY.dev'
/bin/tar: Ignoring unknown extended header keyword `SCHILY.ino'
/bin/tar: Ignoring unknown extended header keyword `SCHILY.nlink'
/bin/tar: Ignoring unknown extended header keyword `SCHILY.dev'
/bin/tar: Ignoring unknown extended header keyword `SCHILY.ino'
/bin/tar: Ignoring unknown extended header keyword `SCHILY.nlink'
/bin/tar: Ignoring unknown extended header keyword `SCHILY.dev'
/bin/tar: Ignoring unknown extended header keyword `SCHILY.ino'
/bin/tar: Ignoring unknown extended header keyword `SCHILY.nlink'
/bin/tar: Ignoring unknown extended header keyword `SCHILY.dev'
/bin/tar: Ignoring unknown extended header keyword `SCHILY.ino'
/bin/tar: Ignoring unknown extended header keyword `SCHILY.nlink'
/bin/tar: Ignoring unknown extended header keyword `SCHILY.dev'
/bin/tar: Ignoring unknown extended header keyword `SCHILY.ino'
/bin/tar: Ignoring unknown extended header keyword `SCHILY.nlink'
Deployment id is b7d53465
Distributing deployment
Distribution status: success
Activating deployment
Deploying WildFly
Starting wildfly cart
Timed out waiting for http listening port
Activation status: failure
Activation failed for the following gears:
undefined method `values' for nil:NilClass
Error deploying local file. You can try to deploy manually with:
ssh -t 53cc68dfe0b8cd921f000035@map-tweetstream.rhcloud.com 'oo-binary-deploy'
SSH command finished with exit status = 255

我做错了什么?

最佳答案

tweetstream-archive.tar.gz 的布局与 OpenShift 部署存档的布局不匹配。对于 WildFly,正确的布局是:

build_dependencies/
dependencies/
jbosseap/
deployments/
tweetstream.war
repo/
.openshift/ # optional

也就是说,WAR 文件必须位于 dependencies/jbosseap/deployments 目录中,并且 binary-deployment 目录不能是存档的一部分。另请参阅:https://www.openshift.com/kb/kb-e1088-how-to-deploy-pre-compiled-java-applications-war-and-ear-files-onto-your-openshift-gear

关于java - OpenShift:无法在 Wildfly 上部署二进制应用程序,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/24856603/

28 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com