Re: Customise shutdown signal at the s6-rc level?

From: Joan Picanyol i Puig <lists-supervision_at_biaix.org>
Date: Tue, 2 May 2017 13:03:48 +0200

* Casper Ti. Vector <caspervector_at_gmail.com> [20170502 12:48]:
> On Tue, May 02, 2017 at 08:51:19AM +0000, Laurent Bercot wrote:
> > If I were to work on a more official, better integrated solution, I would
> > do it at the s6-supervise level. I would not implement custom control
> > scripts, for the reasons indicated in the above link, but it would
> > probably be possible to implement a safer solution, such as reading a file
> > containing the name of the signal to send when s6-svc -d is called.
>
> I see. Now I also think that using a `shutdown-signal' file seems to be
> the least intrusive way. Considering the hangup problem, I think the
> format of the file can be described as something like
> > signal_1 timeout_1 signal_2 timeout_2 ... signal_n [timeout_n]
> where the last timeout, when present, indicates that SIGKILL shall be
> sent if that timeout elapses; the default is obviously
> > SIGTERM

Doesn't

    svc -wD -T1000 servicedir || svc -k servicedir

do what you want for the "hangup problem" ?
Received on Tue May 02 2017 - 11:03:48 UTC

This archive was generated by hypermail 2.3.0 : Sun May 09 2021 - 19:44:19 UTC