tom | 5c25570 | 2014-09-18 06:57:39 -0700 | [diff] [blame] | 1 | #!/bin/bash |
Pavlin Radoslavov | 9141379 | 2014-10-15 11:00:32 -0700 | [diff] [blame] | 2 | # ----------------------------------------------------------------------------- |
tom | 5c25570 | 2014-09-18 06:57:39 -0700 | [diff] [blame] | 3 | # ONOS command-line client |
Pavlin Radoslavov | 9141379 | 2014-10-15 11:00:32 -0700 | [diff] [blame] | 4 | # ----------------------------------------------------------------------------- |
tom | 5c25570 | 2014-09-18 06:57:39 -0700 | [diff] [blame] | 5 | |
Yuta HIGUCHI | 885089b | 2014-11-04 09:33:17 -0800 | [diff] [blame] | 6 | if [ -z "${JAVA_HOME}" ]; then |
| 7 | if [ -x /usr/libexec/java_home ]; then |
| 8 | export JAVA_HOME=$(/usr/libexec/java_home -v 1.8) |
| 9 | elif [ -d /usr/lib/jvm/java-8-oracle ]; then |
| 10 | export JAVA_HOME="/usr/lib/jvm/java-8-oracle" |
| 11 | elif [ -d /usr/lib/jvm/java-7-openjdk-amd64 ]; then |
| 12 | export JAVA_HOME="/usr/lib/jvm/java-7-openjdk-amd64" |
| 13 | fi |
| 14 | fi |
tom | 5c25570 | 2014-09-18 06:57:39 -0700 | [diff] [blame] | 15 | |
Thomas Vachuska | b105fd4 | 2014-10-20 09:02:27 -0700 | [diff] [blame] | 16 | cd $(dirname $0)/../apache-karaf-$KARAF_VERSION/bin |
Thomas Vachuska | 4b42077 | 2014-10-30 16:46:17 -0700 | [diff] [blame] | 17 | ./client -h localhost -u karaf "$@" |