[PATCH] run: gracefully handle SIGHUP, SIGQUIT, SIGTERM
jtomko at redhat.com
Thu Mar 10 07:17:37 UTC 2022
On a Wednesday in 2022, Daniel P. Berrangé wrote:
>When using thue 'run' script to launch a daemon, it is intended to
>temporarily stop the systemd units and re-start them again after.
>When using this script over an SSH connection, it will get SIGHUP
>if the connection goes away, and in this case it fails to re-start
>the systemd units. We need to catch SIGHUP and turn it into a
>normal python exception. For good measure we do the same for
>SIGQUIT and SIGTERM too. SIGINT already gets turned into an
>exception by default which we handle.
>Signed-off-by: Daniel P. Berrangé <berrange at redhat.com>
> run.in | 10 ++++++++++
> 1 file changed, 10 insertions(+)
Reviewed-by: Ján Tomko <jtomko at redhat.com>
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 488 bytes
Desc: not available
More information about the libvir-list