从Play Framework引发战争 [英] Generate war from Play Framework

查看:67
本文介绍了从Play Framework引发战争的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

有没有可用于从Play Framework Project产生战争的插件?

Is there a plugin that can be used to generate war from a Play Framework Project?

c:\>myproject>play war

上面提到的

命令会产生战争,但是当部署在Weblogic或Websphere上时,不会部署. 过去曾尝试过,但未能成功完成部署.

Command mentioned above does the war generation but when deployed on Weblogic or Websphere, it does not get deployed. Tried it in the past but was not successful in getting the deployment successful.

推荐答案

此页面一定会帮助您了解生成war文件所需的配置... https://github.com/play2war/play2-war-plugin/wiki/配置

This page will certainly help you to understand about the configurations required for generating war files... https://github.com/play2war/play2-war-plugin/wiki/Configuration

通常,您必须在添加配置的地方进行更改:
1. plugins.sbt(project-root/project/)
2. build.sbt (project-root)

Generally you have to make changes at places for adding configurations:
1. plugins.sbt(project-root/project/)
2. build.sbt (project-root)

  1. plugins.sbt

addSbtPlugin("com.github.play2war" % "play2-war-plugin" % "1.4-beta1")

  1. build.sbt

  1. build.sbt

import com.github.play2war.plugin._

libraryDependencies ++= Seq(
  "com.github.play2war" % "play2-war_2.9.1" % "0.8.2"   # Change version
)

 Play2WarPlugin.play2WarSettings

 Play2WarKeys.servletVersion := "2.5" # Change as per your requirement(3.0 or 3.1 etc)

addSbtPlugin("com.github.play2war"%"play2-war-plugin"%"1.4-beta1")

addSbtPlugin("com.github.play2war" % "play2-war-plugin" % "1.4-beta1")

运行[sbt war]

Run [ sbt war]

这篇关于从Play Framework引发战争的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆