Liferay 的“热部署”过程确保插件使用正确版本的 Liferay 库,与当前安装的门户相匹配。如果您的服务器不支持热部署,还有另一种推荐的方法来注入这些设置和库。看看这些属性:
#
# Set this to true to enable auto deploy of layout templates, portlets, and
# themes.
#
auto.deploy.enabled=true
#
# Set the directory to scan for layout templates, portlets, and themes to
# auto deploy.
#
auto.deploy.deploy.dir=${liferay.home}/deploy
#
# Set the directory where auto deployed WARs are copied to. The application
# server or servlet container must know to listen on that directory.
# Different containers have different hot deploy paths. For example, Tomcat
# listens on "${catalina.base}/webapps" whereas JBoss listens on
# "${jboss.home.dir}/deploy". Set a blank directory to automatically use the
# application server specific directory.
#
auto.deploy.dest.dir=
auto.deploy.default.dest.dir=../webapps
auto.deploy.geronimo.dest.dir=${org.apache.geronimo.home.dir}/deploy
auto.deploy.glassfish.dest.dir=${com.sun.aas.instanceRoot}/autodeploy
auto.deploy.jboss.dest.dir=${jboss.home.dir}/standalone/deployments
auto.deploy.jetty.dest.dir=${jetty.home}/webapps
auto.deploy.jonas.dest.dir=${jonas.base}/deploy
auto.deploy.resin.dest.dir=${resin.home}/webapps
auto.deploy.tomcat.dest.dir=${catalina.base}/webapps
auto.deploy.weblogic.dest.dir=${env.DOMAIN_HOME}/autodeploy
auto.deploy.websphere.dest.dir=${env.USER_INSTALL_ROOT}/wsadmin-deploy
您可以在 portal-ext.properties 中覆盖这些。将您的 JBoss 配置为在此处侦听任何目录,${liferay.home}/deploy
并将其 dest 目录配置到其他位置:auto.deploy.jboss.dest.dir=${liferay.home}/for-installation-on-jboss
. 然后将 dest.dir 的结果内容打包为 *.war 或 *.ear 文件,并像往常一样将其部署在您的 JBoss 服务器上。这将包含所需的所有设置和库。
${liferay.home}/for-installation-on-jboss
在尝试“部署”到它之前,请确保它存在。