diff --git a/xo-install.sh b/xo-install.sh index 8c457b8..8980f9f 100755 --- a/xo-install.sh +++ b/xo-install.sh @@ -706,7 +706,7 @@ function InstallXO { InstallXOPlugins # shutdown possibly running xo-server - if [[ $(runcmd_stdout "pgrep -f 'node.*xo-server'") ]]; then + if [[ $(runcmd_stdout "pgrep -f '^([a-zA-Z0-9_\/-]+?)node.*xo-server'") ]]; then echo printprog "Shutting down running xo-server" runcmd "/bin/systemctl stop xo-server" || { @@ -991,7 +991,7 @@ function InstallXOProxy { printok "Running installation" # shutdown possibly running xo-server - if [[ $(runcmd_stdout "pgrep -f 'node.*xo-proxy'") ]]; then + if [[ $(runcmd_stdout "pgrep -f '^([a-zA-Z0-9_\/-]+?)node.*xo-proxy'") ]]; then echo printprog "Shutting down running xo-proxy" runcmd "/bin/systemctl stop xo-proxy" || { @@ -1468,7 +1468,7 @@ function StartUpScreen { case $option in 1) - if [[ $(runcmd_stdout "pgrep -f 'node.*xo-server'") ]]; then + if [[ $(runcmd_stdout "pgrep -f '^([a-zA-Z0-9_\/-]+?)node.*xo-server'") ]]; then echo "Looks like xo-server process is already running, consider running update instead. Continue anyway?" read -r -p "[y/N]: " answer case $answer in @@ -1515,7 +1515,7 @@ function StartUpScreen { exit 0 ;; 4) - if [[ $(runcmd_stdout "pgrep -f 'node.*xo-proxy'") ]]; then + if [[ $(runcmd_stdout "pgrep -f '^([a-zA-Z0-9_\/-]+?)node.*xo-proxy'") ]]; then echo "Looks like xo-proxy process is already running, consider running update instead. Continue anyway?" read -r -p "[y/N]: " answer case $answer in