Re: s6-rc: oneshot services do not get their name as arg 1

From: Laurent Bercot <ska-supervision_at_skarnet.org>
Date: Sun, 03 Nov 2024 21:57:32 +0000

>I am wondering why oneshot services do not get their names passed as argument 1, while longruns do.
>Is there a reason for that? If yes, what is it? If not, will this be added?

  Longruns being passed their names as argument is a recent addition:
it was useful to implement dynamic instances in s6. It's a pure s6
feature, not an s6-rc one; it just so happens that a longrun's name in
s6-rc translates to the service directory's name in s6.

  Oneshots aren't being handled by s6, so they did not benefit from that
change. They're only run at the s6-rc level, and s6-rc does not pass
service names as arguments.

  There would be no benefit to doing that, because oneshots do not have
instances, so any up or down script knows exactly what service it is
starting or stopping.

--
  Laurent
Received on Sun Nov 03 2024 - 22:57:32 CET

This archive was generated by hypermail 2.4.0 : Sun Nov 03 2024 - 22:58:00 CET