portals-jetspeed-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From a..@apache.org
Subject svn commit: r587707 - /portals/jetspeed-2/branches/JETSPEED-2.1.3/maven-plugin/plugin.jelly
Date Wed, 24 Oct 2007 00:14:56 GMT
Author: ate
Date: Tue Oct 23 17:14:56 2007
New Revision: 587707

URL: http://svn.apache.org/viewvc?rev=587707&view=rev
Log:
JS2-793: Support deployment of jetspeed under a custom context name (e.g. ROOT) with the maven
1 jetspeed plugin
See: http://issues.apache.org/jira/browse/JS2-793
- Support for Tomcat 5.0.x too which requires the context path to be defined in the context
deployment descriptor (e.g. "" for ROOT)

Modified:
    portals/jetspeed-2/branches/JETSPEED-2.1.3/maven-plugin/plugin.jelly

Modified: portals/jetspeed-2/branches/JETSPEED-2.1.3/maven-plugin/plugin.jelly
URL: http://svn.apache.org/viewvc/portals/jetspeed-2/branches/JETSPEED-2.1.3/maven-plugin/plugin.jelly?rev=587707&r1=587706&r2=587707&view=diff
==============================================================================
--- portals/jetspeed-2/branches/JETSPEED-2.1.3/maven-plugin/plugin.jelly (original)
+++ portals/jetspeed-2/branches/JETSPEED-2.1.3/maven-plugin/plugin.jelly Tue Oct 23 17:14:56
2007
@@ -269,6 +269,11 @@
   <goal name="j2:portal.conf.tomcat" prereqs="j2:_check.required.properties">
     <j:set var="portal.conf.dir" value="${org.apache.jetspeed.portal.home}/${org.apache.jetspeed.portal.conf.dir}"/>
     
     <mkdir dir="${portal.conf.dir}/tomcat"/>
+    <j:set var="contextPath" value="/${org.apache.jetspeed.portal.contextName}"/>
+    <!-- for Tomcat 5.0 which requires the context path to be defined check and adjust
for ROOT deployment -->
+    <j:if test="${contextPath == '/ROOT'}">
+      <j:set var="contextPath" value=""/>        
+    </j:if>
     <j:set var="catalina_version_major" value="${org.apache.jetspeed.catalina.version.major}"/>
     <j:choose>
       <j:when test="${catalina_version_major == '5.5'}">
@@ -277,11 +282,12 @@
       <j:otherwise>
         <j:set var="context_file_source" value="jetspeed-tomcat-5.xml"/>
       </j:otherwise>
-    </j:choose>
+    </j:choose>    
     <copy file="${org.apache.jetspeed.plugin.root}/plugin-resources/conf/tomcat/${context_file_source}"
           tofile="${portal.conf.dir}/tomcat/context.xml" overwrite="true">
       <filterset begintoken="@" endtoken="@">
         <filter token="CONTEXT" value="${org.apache.jetspeed.portal.contextName}"/>
+        <filter token="CONTEXTPATH" value="${contextPath}"/>
         <filter token="USERNAME" value="${org.apache.jetspeed.production.database.user}"/>
         <filter token="PASSWORD" value="${org.apache.jetspeed.production.database.password}"/>
         <filter token="DRIVER" value="${org.apache.jetspeed.production.database.driver}"/>



---------------------------------------------------------------------
To unsubscribe, e-mail: jetspeed-dev-unsubscribe@portals.apache.org
For additional commands, e-mail: jetspeed-dev-help@portals.apache.org


Mime
View raw message