-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathrailo
executable file
·41 lines (34 loc) · 1.04 KB
/
railo
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
40
41
#!/usr/bin/env bash
CURRPATH=$(pwd)
PARAMS=""
for var in "$@"
do
PARAMS=${PARAMS}~"$var"
done
if [ -n "$1" ]
then
if [ "$1" == "run" ]
then
# echo $(dirname $0)/lib/ext/railo-cli.jar
cd $(dirname $0)
java -jar lib/ext/railo-cli.jar -webroot=$CURRPATH uri=$2?$3
elif [ "$1" == "start" ]
then
cd $(dirname $0)
#export JAVA_OPTIONS="${JAVA_OPTIONS} -javaagent:lib/ext/railo-inst.jar"
java -jar -DSTOP.PORT=8887 -DSTOP.KEY=railo -Xms256M -Xmx512M lib/start.jar -Drailo.webroot=$CURRPATH --exec
elif [ "$1" == "stop" ]
then
#echo "Starging up Railo as a server"
cd $(dirname $0)
java -jar -DSTOP.PORT=8887 -DSTOP.KEY=railo lib/start.jar --stop
else
#echo "Calling plugin $1"
cd $(dirname $0)
java -jar lib/ext/railo-cli.jar -webroot=./webroot/ -uri='/runner.cfm?currentpath='${CURRPATH}'¶ms='$PARAMS
fi
else
cd $(dirname $0)
java -jar lib/ext/railo-cli.jar -webroot=./webroot/ -uri='/help.cfm'
fi
#java -jar ./lib/ext/railo-cli.jar -webroot=./webroot/ -uri='/runner.cfm?currentpath='${CURRPATH}'¶ms='$PARAMS