mirror of
https://github.com/opennetworkinglab/onos.git
synced 2025-10-16 18:02:05 +02:00
29 lines
1.0 KiB
Bash
Executable File
29 lines
1.0 KiB
Bash
Executable File
#!/bin/bash
|
|
# -----------------------------------------------------------------------------
|
|
# Makes sure local ONOS karaf instance is primed & staged and then launches
|
|
# karaf using the supplied arguments.
|
|
# -----------------------------------------------------------------------------
|
|
|
|
echo "This command is deprecated and will be removed imminently!!!"
|
|
echo "Please use 'buck run onos-local' instead."
|
|
echo "e.g.: buck run onos-local -- clean debug"
|
|
echo " or: buck run onos-local -- debug"
|
|
|
|
|
|
. $ONOS_ROOT/tools/build/envDefaults
|
|
if [ -L $ONOS_TAR ]; then
|
|
echo "WARN: This script does not support deploying buck artifacts"
|
|
fi
|
|
|
|
SETUP_OPTS=""
|
|
# FIXME: temporarily fix 500 error in GUI, need to be improved with a better way
|
|
if echo $* | egrep "\bclean\b"; then
|
|
export KARAF_ROOT=${KARAF_ROOT:-~/Applications/apache-karaf-$KARAF_VERSION}
|
|
export STAGE=$(dirname $KARAF_ROOT)
|
|
echo "Removing data directories..."
|
|
[ -d $KARAF_ROOT ] && rm -fr $STAGE/data
|
|
SETUP_OPTS="${SETUP_OPTS} clean"
|
|
fi
|
|
|
|
onos-setup-karaf $SETUP_OPTS && karaf "$@"
|