forked from filodb/FiloDB
-
Notifications
You must be signed in to change notification settings - Fork 2
/
filodb-dev-start.sh
executable file
·39 lines (33 loc) · 1.05 KB
/
filodb-dev-start.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
#!/usr/bin/env bash
set -e
# set -x
function showHelp {
echo "`basename $0` [-h] [-c arg] [-l arg] [-p]"
echo " -h help"
echo " -c takes server config path as argument"
echo " -l takes log file suffix as argument"
echo " -p selects a randomly available akka tcp and http port"
}
CONFIG=conf/timeseries-filodb-server.conf
LOG_SUFFIX=1
AKKA_PORT_ARG=""
while getopts "hc:l:ps" opt; do
case "$opt" in
h|\?) showHelp
exit 1
;;
c) CONFIG=$OPTARG
;;
l) LOG_SUFFIX=$OPTARG
;;
p) PORTS_ARG="-Dakka.remote.netty.tcp.port=0 -Dfilodb.http.bind-port=0"
;;
esac
done
cd "$(dirname "$0")"
if [ ! -f standalone/target/scala-2.11/standalone-assembly-*-SNAPSHOT.jar ]; then
echo "Standalone assembly not found. Building..."
sbt standalone/assembly
fi
echo "Starting FiloDB standalone server..."
java -Xmx4G $PORTS_ARG -Dconfig.file=$CONFIG -DlogSuffix=$LOG_SUFFIX -cp standalone/target/scala-2.11/standalone-assembly-*-SNAPSHOT.jar filodb.standalone.FiloServer &