mirror of
https://git.savannah.gnu.org/git/guix.git
synced 2025-01-31 14:56:54 +01:00
shepherd: 'read-pid-file/container' terminates the whole process group.
This mirrors a change made in the Shepherd 0.8.0. Previously, upon startup failure, we could have left processes behind. * gnu/build/shepherd.scm (read-pid-file/container): Kill (- PID) instead of PID.
This commit is contained in:
parent
b6b95685d0
commit
8a02e45d93
1 changed files with 2 additions and 1 deletions
|
@ -105,7 +105,8 @@ (define* (read-pid-file/container pid pid-file #:key (max-delay 5))
|
|||
(read-pid-file pid-file
|
||||
#:max-delay max-delay)))
|
||||
(#f
|
||||
(catch-system-error (kill pid SIGTERM))
|
||||
;; Send SIGTERM to the whole process group.
|
||||
(catch-system-error (kill (- pid) SIGTERM))
|
||||
#f)
|
||||
((? integer? container-pid)
|
||||
;; XXX: When COMMAND is started in a separate PID namespace, its
|
||||
|
|
Loading…
Reference in a new issue