Skip to content

Commit 1d827b1

Browse files
authored
Update v-list-sys-services (hestiacp#4022)
fix for v-list-sys-services debian buster doesn't support option -d for pidof
1 parent 8e8371f commit 1d827b1

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

bin/v-list-sys-services

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -87,9 +87,9 @@ get_srv_state() {
8787

8888
# Searching related pids
8989
if [ -z $3 ]; then
90-
pids=$(pidof -d '|' $name)
90+
pids=$(pidof $name | tr ' ' '|')
9191
else
92-
pids=$(pidof -d '|' -x $name)
92+
pids=$(pidof -x $name | tr ' ' '|')
9393
fi
9494
if [ -z "$pids" ] && [ "$name" != 'nginx' ]; then
9595
pids=$(pgrep $name | tr '\n' '|')

0 commit comments

Comments
 (0)