fix: simpler server CLI tool usage
This commit is contained in:
parent
df7df838cf
commit
18602a42f1
1 changed files with 4 additions and 2 deletions
|
@ -7,7 +7,7 @@ run_init_command() {
|
||||||
shift
|
shift
|
||||||
if ! [ -f state/init-$stage ]; then
|
if ! [ -f state/init-$stage ]; then
|
||||||
echo "Running initialization stage $stage"
|
echo "Running initialization stage $stage"
|
||||||
echo " --> $@"
|
echo " --> $*"
|
||||||
if /app/entrypoint.sh tool "$*"
|
if /app/entrypoint.sh tool "$*"
|
||||||
then
|
then
|
||||||
touch state/init-$stage
|
touch state/init-$stage
|
||||||
|
@ -53,10 +53,12 @@ if [ "$cmd" == server ]; then
|
||||||
elif [ "$cmd" == shell ]; then
|
elif [ "$cmd" == shell ]; then
|
||||||
exec /bin/sh
|
exec /bin/sh
|
||||||
elif [ "$cmd" == tool ]; then
|
elif [ "$cmd" == tool ]; then
|
||||||
|
tool="$1"
|
||||||
|
shift
|
||||||
exec /usr/bin/java \
|
exec /usr/bin/java \
|
||||||
-Dlog4j.configuration=log4j.properties \
|
-Dlog4j.configuration=log4j.properties \
|
||||||
-jar server.jar \
|
-jar server.jar \
|
||||||
--run-tool "$@"
|
--run-tool "$tool" "$*"
|
||||||
else
|
else
|
||||||
echo "Invalid command '$cmd'" >&2
|
echo "Invalid command '$cmd'" >&2
|
||||||
exit 1
|
exit 1
|
||||||
|
|
Loading…
Add table
Reference in a new issue