`
阿男bluedash
  • 浏览: 167993 次
  • 性别: Icon_minigender_1
  • 来自: 北京
社区版块
存档分类
最新评论

JBoss AS7 - 部署

阅读更多
首先是启动AS7[1],然后进入管理终端:

%  ./jboss-admin.sh 
You are disconnected at the moment. Type 'connect' to connect to the server or 'help' for the list of supported commands.
[disconnected /] connect localhost
Connected to standalone controller at localhost:9999


部署项目的命令很简单:

[standalone@localhost:9999 /] deploy <your_war_or_ear_file>


查询当然AS7服务器中部署的内容有多种方法,首先介绍最好记的方法:AS7支持使用ls像目录一样查看服务器中的资源:

[standalone@localhost:9999 /] ls
extension              core-service           path                   subsystem              system-property        deployment             interface              socket-binding-group


因此我们可以很方便地查看deployment中的内容:

[standalone@localhost:9999 /] ls deployment              
my-webapp.war


这是方法之一;还有一种方法是使用终端中的查询命令:

[standalone@localhost:9999 /] :read-children-names(child-type=deployment)
{
    "outcome" => "success",
    "result" => ["my-webapp.war"]
}


卸掉项目则使用undeploy命令:

[standalone@localhost:9999 /] undeploy my-webapp.war
Successfully undeployed my-webapp.war.


更多使用方法请查阅参考资料[2]。

*参考资料*

[1] 本系列文章都假设AS7运行在standalone模式。

[2] "AS7关于deploy命令说明的官方文档":https://docs.jboss.org/author/display/AS7/Admin+Guide#AdminGuide-DeploymentCommands
分享到:
评论

相关推荐

Global site tag (gtag.js) - Google Analytics