Skip to content

Commit ce1f90d

Browse files
committed
Fix cancel
1 parent 06b36c9 commit ce1f90d

File tree

1 file changed

+2
-2
lines changed
  • src/main/resources/bash-job-scheduler/process

1 file changed

+2
-2
lines changed

src/main/resources/bash-job-scheduler/process/cancel.bash

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
1-
pid=$(ps aux | grep SingleShotComp | grep -v grep | grep $POD_NAME | tr -s ' ' | cut -d ' ' -f 2)
1+
pid=$(ps aux | grep SingleShotComp | grep -v grep | grep -v "bash -c" | grep $JOB_ID | tr -s ' ' | cut -d ' ' -f 2)
22
found=$(echo "$pid" | wc -l)
33
if [ -z "$pid" ]; then
44
echo 'process not found'
55
elif [ $found == 1 ]; then
6-
echo "kill $pid"
6+
echo "kill: $pid"
77
kill $pid
88
else
99
echo "found $found processes"

0 commit comments

Comments
 (0)