diff options
Diffstat (limited to 'distribution/reservesys/reservesys.sh')
-rwxr-xr-x | distribution/reservesys/reservesys.sh | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/distribution/reservesys/reservesys.sh b/distribution/reservesys/reservesys.sh index 489a78c..24d45bb 100755 --- a/distribution/reservesys/reservesys.sh +++ b/distribution/reservesys/reservesys.sh @@ -5,7 +5,12 @@ # If we timeout from either local or external watchdog # we will have a warn/fail recorded anyway. # -trap 'exit 0' 15 + +cleanup() +{ + kill -9 $1 + exit 0 +} # Functions RprtRslt() @@ -213,8 +218,10 @@ fi # Run another copy of restraint on a different port # This makes it easy to develop/debug new tasks. -restraintd --port 8082 +restraintd --port 8082 & +pid=$! +trap "cleanup $pid" 15 # We stay running in restraint.. while (true); do |