Skip to content

Commit

Permalink
Fix handling of quoted args in start scripts (#207)
Browse files Browse the repository at this point in the history
  • Loading branch information
martin-traverse committed Nov 18, 2022
1 parent 522e0ad commit 9287b2c
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions dist/scripts/service-ctrl.sh
Original file line number Diff line number Diff line change
Expand Up @@ -196,9 +196,9 @@ run() {
CWD=`pwd`
cd "\${RUN_DIR}"
if [ "\${SECRET_KEY}" = "" ]; then
"\${JAVA_CMD}" \${JAVA_OPTS} \$APPLICATION_CLASS --config "\${CONFIG_FILE}" \$@
"\${JAVA_CMD}" \${JAVA_OPTS} \$APPLICATION_CLASS --config "\${CONFIG_FILE}" "\$@"
else
"\${JAVA_CMD}" \${JAVA_OPTS} \$APPLICATION_CLASS --config "\${CONFIG_FILE}" --secret-key "\${SECRET_KEY}" \$@
"\${JAVA_CMD}" \${JAVA_OPTS} \$APPLICATION_CLASS --config "\${CONFIG_FILE}" --secret-key "\${SECRET_KEY}" "\$@"
fi
cd "\${CWD}"
}
Expand Down Expand Up @@ -228,9 +228,9 @@ start() {
CWD=`pwd`
cd "\${RUN_DIR}"
if [ "\${SECRET_KEY}" = "" ]; then
"\${JAVA_CMD}" \${JAVA_OPTS} \$APPLICATION_CLASS --config "\${CONFIG_FILE}" \$@ &
"\${JAVA_CMD}" \${JAVA_OPTS} \$APPLICATION_CLASS --config "\${CONFIG_FILE}" "\$@" &
else
"\${JAVA_CMD}" \${JAVA_OPTS} \$APPLICATION_CLASS --config "\${CONFIG_FILE}" --secret-key "\${SECRET_KEY}" \$@ &
"\${JAVA_CMD}" \${JAVA_OPTS} \$APPLICATION_CLASS --config "\${CONFIG_FILE}" --secret-key "\${SECRET_KEY}" "\$@" &
fi
PID=\$!
cd "\${CWD}"
Expand Down Expand Up @@ -360,11 +360,11 @@ kill_all() {
case "\$1" in
run)
shift
run \$@
run "\$@"
;;
start)
shift
start \$@
start "\$@"
;;
stop)
stop
Expand Down

0 comments on commit 9287b2c

Please sign in to comment.