incubator-cloudstack-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mc...@apache.org
Subject [32/50] [abbrv] git commit: refs/heads/vim51_win8 - CLOUDSTACK-1181: Find by catalina.home property first
Date Wed, 13 Feb 2013 01:07:00 GMT
CLOUDSTACK-1181: Find by catalina.home property first

The previous commit fails if a person had defined CATALINA_HOME already.
Instead of system env variable, get any passed variable 'catalina.home' and find
the file in that path.

Signed-off-by: Rohit Yadav <bhaisaab@apache.org>


Project: http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/commit/44287d20
Tree: http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/tree/44287d20
Diff: http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/diff/44287d20

Branch: refs/heads/vim51_win8
Commit: 44287d20c0c52a57db0c498f7e23793109c920f2
Parents: 23f7267
Author: Rohit Yadav <bhaisaab@apache.org>
Authored: Mon Feb 11 12:14:46 2013 +0530
Committer: Rohit Yadav <bhaisaab@apache.org>
Committed: Mon Feb 11 12:14:46 2013 +0530

----------------------------------------------------------------------
 developer/pom.xml                             |   10 ++++++++--
 utils/src/com/cloud/utils/PropertiesUtil.java |    8 ++++----
 2 files changed, 12 insertions(+), 6 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/44287d20/developer/pom.xml
----------------------------------------------------------------------
diff --git a/developer/pom.xml b/developer/pom.xml
index b0ae356..dba7b38 100644
--- a/developer/pom.xml
+++ b/developer/pom.xml
@@ -179,8 +179,8 @@
               </arguments>
               <systemProperties>
                 <systemProperty>
-                  <key>CATALINA_HOME</key>
-                  <value>${project.parent.basedir}/utils/</value>
+                  <key>catalina.home</key>
+                  <value>${project.parent.basedir}/utils</value>
                 </systemProperty>
               </systemProperties>
             </configuration>
@@ -287,6 +287,12 @@
                 <argument>--rootpassword=${db.root.password}</argument>
                 <!-- enable verbosity by -v or dash-dash-verbose -->
               </arguments>
+              <systemProperties>
+                <systemProperty>
+                  <key>catalina.home</key>
+                  <value>${project.parent.basedir}/utils</value>
+                </systemProperty>
+              </systemProperties>
             </configuration>
           </plugin>
         </plugins>

http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/44287d20/utils/src/com/cloud/utils/PropertiesUtil.java
----------------------------------------------------------------------
diff --git a/utils/src/com/cloud/utils/PropertiesUtil.java b/utils/src/com/cloud/utils/PropertiesUtil.java
index 90f8af8..e256fce 100755
--- a/utils/src/com/cloud/utils/PropertiesUtil.java
+++ b/utils/src/com/cloud/utils/PropertiesUtil.java
@@ -70,14 +70,14 @@ public class PropertiesUtil {
         if (file.exists()) {
             return file;
         }
-        
-        newPath = System.getenv("CATALINA_HOME");
+
+        newPath = System.getProperty("catalina.home");
         if (newPath == null) {
-        	newPath = System.getenv("CATALINA_BASE");
+            newPath = System.getenv("CATALINA_HOME");
         }
         
         if (newPath == null) {
-        	newPath = System.getProperty("catalina.home");
+            newPath = System.getenv("CATALINA_BASE");
         }
         
         if (newPath == null) {


Mime
View raw message