Till Westmann | 7ce7c4b | 2014-11-10 06:34:23 -0800 | [diff] [blame] | 1 | #!/usr/bin/env bash |
| 2 | #/* |
| 3 | # Copyright 2009-2013 by The Regents of the University of California |
| 4 | # Licensed under the Apache License, Version 2.0 (the "License"); |
| 5 | # you may not use this file except in compliance with the License. |
| 6 | # you may obtain a copy of the License from |
| 7 | # |
| 8 | # http://www.apache.org/licenses/LICENSE-2.0 |
| 9 | # |
| 10 | # Unless required by applicable law or agreed to in writing, software |
| 11 | # distributed under the License is distributed on an "AS IS" BASIS, |
| 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 13 | # See the License for the specific language governing permissions and |
| 14 | # limitations under the License. |
| 15 | #*/ |
Till Westmann | fd733ee | 2014-07-10 00:57:37 -0700 | [diff] [blame] | 16 | if [ -z $MANAGIX_HOME ] |
ramangrover29 | 116eb97 | 2013-02-20 20:47:35 +0000 | [diff] [blame] | 17 | then |
Till Westmann | fd733ee | 2014-07-10 00:57:37 -0700 | [diff] [blame] | 18 | pushd $(dirname $0) >/dev/null |
| 19 | cd .. |
| 20 | export MANAGIX_HOME=$(pwd) |
| 21 | popd >/dev/null |
ramangrover29 | 116eb97 | 2013-02-20 20:47:35 +0000 | [diff] [blame] | 22 | fi |
| 23 | |
ramangrover29 | 7265aec | 2013-03-16 01:09:54 +0000 | [diff] [blame] | 24 | for jar in `ls $MANAGIX_HOME/lib/*.jar` |
ramangrover29 | 116eb97 | 2013-02-20 20:47:35 +0000 | [diff] [blame] | 25 | do |
ramangrover29 | 7265aec | 2013-03-16 01:09:54 +0000 | [diff] [blame] | 26 | if [ -z $MANAGIX_CLASSPATH ] |
ramangrover29 | 116eb97 | 2013-02-20 20:47:35 +0000 | [diff] [blame] | 27 | then |
ramangrover29 | 7265aec | 2013-03-16 01:09:54 +0000 | [diff] [blame] | 28 | MANAGIX_CLASSPATH=$jar |
ramangrover29 | 116eb97 | 2013-02-20 20:47:35 +0000 | [diff] [blame] | 29 | else |
ramangrover29 | 7265aec | 2013-03-16 01:09:54 +0000 | [diff] [blame] | 30 | MANAGIX_CLASSPATH=$MANAGIX_CLASSPATH:$jar |
ramangrover29 | 116eb97 | 2013-02-20 20:47:35 +0000 | [diff] [blame] | 31 | fi |
| 32 | done |
| 33 | |
ramangrover29 | 7265aec | 2013-03-16 01:09:54 +0000 | [diff] [blame] | 34 | MANAGIX_CLASSPATH=$MANAGIX_CLASSPATH:$MANAGIX_HOME/conf/log4j.properties |
Ian Maxon | f18bba2 | 2015-08-21 12:35:14 -0700 | [diff] [blame] | 35 | java $JAVA_OPTS -Dlog4j.configuration=file:$MANAGIX_HOME/conf/log4j.properties -cp $MANAGIX_CLASSPATH org.apache.asterix.installer.driver.InstallerDriver $@ |