From d1be92348104fa5fb82914a810a9572dac656cc0 Mon Sep 17 00:00:00 2001 From: Brendan Germain Date: Thu, 6 Nov 2014 14:02:15 -0500 Subject: [PATCH] updated jetty start command to speficy /bin/bash as the shell. With out this you cannot use su to run commands as jetty becuase the user shell is set to /bin/false --- templates/default/jetty-8.sh.erb | 2 +- templates/default/jetty-9.sh.erb | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/templates/default/jetty-8.sh.erb b/templates/default/jetty-8.sh.erb index ca0550b..8f085ec 100644 --- a/templates/default/jetty-8.sh.erb +++ b/templates/default/jetty-8.sh.erb @@ -446,7 +446,7 @@ case "$ACTION" in touch "$JETTY_PID" chown "$JETTY_USER" "$JETTY_PID" # FIXME: Broken solution: wordsplitting, pathname expansion, arbitrary command execution, etc. - su - "$JETTY_USER" -c " + su -m "$JETTY_USER" -s /bin/bash -c " exec ${RUN_CMD[*]} --daemon & disown \$! echo \$! > '$JETTY_PID'" diff --git a/templates/default/jetty-9.sh.erb b/templates/default/jetty-9.sh.erb index 7d7bbdc..8146b6e 100644 --- a/templates/default/jetty-9.sh.erb +++ b/templates/default/jetty-9.sh.erb @@ -466,7 +466,7 @@ case "$ACTION" in touch "$JETTY_PID" chown "$JETTY_USER" "$JETTY_PID" # FIXME: Broken solution: wordsplitting, pathname expansion, arbitrary command execution, etc. - su - "$JETTY_USER" -c " + su - "$JETTY_USER" -s /bin/bash -c " exec ${RUN_CMD[*]} --daemon & disown \$! echo \$! > '$JETTY_PID'" @@ -601,4 +601,4 @@ case "$ACTION" in ;; esac -exit 0 \ No newline at end of file +exit 0