Author: thomas.heute(a)jboss.com
Date: 2010-02-15 14:44:40 -0500 (Mon, 15 Feb 2010)
New Revision: 1700
Modified:
maven/packager/trunk/src/main/javascript/eXo/server/JbossEar.js
maven/packager/trunk/src/main/javascript/eXo/server/Tomcat.js
Log:
GTNMAVEN-2: Deliver 01eXoResources.war exploded
GTNMAVEN-3: Move configuration file in an easy to modify location
Modified: maven/packager/trunk/src/main/javascript/eXo/server/JbossEar.js
===================================================================
--- maven/packager/trunk/src/main/javascript/eXo/server/JbossEar.js 2010-02-15 19:39:40
UTC (rev 1699)
+++ maven/packager/trunk/src/main/javascript/eXo/server/JbossEar.js 2010-02-15 19:44:40
UTC (rev 1700)
@@ -14,6 +14,8 @@
this.deployLibDir = this.serverHome + "/server/default/deploy/gatein.ear";
this.deployWebappDir = this.serverHome +
"/server/default/deploy/gatein.ear";
this.deployEarDir = this.serverHome + "/server/default/deploy/";
+ this.configDir = this.serverHome + "/server/default/conf";
+ this.gateInConfigDir = this.configDir + "/gatein";
this.patchDir = this.serverHome;// + "/server/default"; //because we have to
// patch bin/ directory
}
@@ -120,9 +122,11 @@
ServerUtil.addClasspathForWar(this.deployLibDir);
// Use jboss PrefixSorter deployer
- var eXoResourcesFile = new java.io.File(this.deployWebappDir +
"/eXoResources.war");
- var neweXoResourcesFile = new java.io.File(this.deployWebappDir +
"/01eXoResources.war");
- eXoResourcesFile.renameTo(neweXoResourcesFile);
+ // Explode and rename eXoResources.war
+ var eXoResourcesFileName = this.deployWebappDir + "/eXoResources.war";
+ var neweXoResourcesDirectoryName = this.deployWebappDir +
"/01eXoResources.war";
+ eXo.core.IOUtil.unzip(eXoResourcesFileName, neweXoResourcesDirectoryName);
+ eXo.core.IOUtil.remove(eXoResourcesFileName);
var portalFile = new java.io.File(this.deployWebappDir + "/" +
product.portalwar);
var newPortalFile = new java.io.File(this.deployWebappDir +
"/02portal.war");
@@ -142,6 +146,10 @@
eXo.core.IOUtil.remove(file);
}
}
+
+ // Copy configuration
+ new java.io.File(this.gateInConfigDir).mkdir();
+ eXo.core.IOUtil.cp(eXo.env.currentDir +
"/../../component/common/src/main/java/conf/configuration-jboss.properties",
this.gateInConfigDir + "/configuration.properties")
if (product.integrationTests) {
var fromFile = new java.io.File(libDir, this.MC_INT_DEMO_ARTIFACT + "-" +
this.EXO_KERNEL_VER + ".jar");
Modified: maven/packager/trunk/src/main/javascript/eXo/server/Tomcat.js
===================================================================
--- maven/packager/trunk/src/main/javascript/eXo/server/Tomcat.js 2010-02-15 19:39:40 UTC
(rev 1699)
+++ maven/packager/trunk/src/main/javascript/eXo/server/Tomcat.js 2010-02-15 19:44:40 UTC
(rev 1700)
@@ -8,6 +8,8 @@
this.cleanServer = eXo.env.cleanServer;
this.deployLibDir = this.serverHome + "/lib";
this.deployWebappDir = this.serverHome + "/webapps";
+ this.configDir = this.serverHome + "/conf";
+ this.gateInConfigDir = this.configDir + "/gatein";
this.patchDir = this.serverHome;
this.pluginVersion = "trunk";
}
@@ -118,6 +120,11 @@
}
Tomcat.prototype.postDeploy = function(product) {
+
+ // Copy configuration
+ new java.io.File(this.gateInConfigDir).mkdir();
+ eXo.core.IOUtil.cp(eXo.env.currentDir +
"/../../component/common/src/main/java/conf/configuration-tomcat.properties",
this.gateInConfigDir + "/configuration.properties")
+
var configFileInWar = "WEB-INF/conf/configuration.xml";
var portalwar = new java.io.File(this.deployWebappDir + "/" +
product.portalwar);
eXo.System.info("CONF", "Patching " + configFileInWar + " in
" + portalwar + " : remove wsrp configuration");
Show replies by date