我有一个带有grails的web应用程序,我想使用.war文件在cPanel中部署这个web应用程序。我遵循这个,首先创建数据库,然后在我的应用程序数据源上添加数据库信息,在cPanel上制作war文件并将war文件上传到PUBLIC_HTML文件,将war文件重命名为压缩文件并解压缩。我检查了url(sampleDomain.com/myApp),但它显示如下错误:
Not Found
The requested URL /myApp was not found on this server.
我不知道如何部署这个war文件。
我使用名为test.war的7za命令创建了这个文件
# file test.war
test.war: 7-zip archive data, version 0.4
我试图在另一台RHEL机器中使用命令解压缩该文件:
# unzip test.war
Archive: test.war
End-of-central-directory signature not found. Either this file is not
a zipfile, or it constitutes one disk of a multi-part archive. In the
latte
我有几个使用Vim的系统,其中一个系统无法查看/编辑压缩文件。我相信我有正确的插件,因为我的Vim 7.0的另一个系统可以与相同的插件正常工作。
我得到一个错误:
$ vi admin.war
~
...
~
***error*** (zip#Browse) unzip not available on your system
我的机器:
$ uname -srmo
Linux 2.6.35.4-rscloud x86_64 GNU/Linux
$ vim --v
VIM - Vi IMproved 7.2 (2008 Aug 9, compiled Sep 28 2010 11:05:08
我使用的是Ansible的解压缩模块,这似乎不适合提取war文件。它适用于.tar。
还有一个开关setype:“SELinux文件上下文的类型部分”,我不确定它是否可以用来将文件类型设置为war。
我试过这个:
-name: Unpack war
unarchive: src=~/wars/mywar.war
dest=/tmp/deploy
setype=war
copy=no
它给出了错误:msg: Failed to find handler to unarchive. Make sure the require
我使用"org.springframework.boot“插件并使用bootWar任务生成我的spring项目的war文件。我希望有一个任务来创建这个war文件的爆炸版本。
使用“war”插件的标准方法是:
task explodedWar(type: Sync) {
into "${war.archivePath.parentFile.getAbsolutePath()}/exploded/${war.archivePath.name}"
with war
}
我如何使用spring/bootWar插件来做同样的事情?