supervision - discussion about system services, daemon supervision, init, runlevel management, and tools such as s6 and runit
 help / color / mirror / Atom feed
* runsvdir under runsv
@ 2007-10-10 13:16 Lasse Kliemann
  2007-10-10 19:42 ` Joan Picanyol i Puig
  0 siblings, 1 reply; 5+ messages in thread
From: Lasse Kliemann @ 2007-10-10 13:16 UTC (permalink / raw)
  To: supervision

[-- Attachment #1: Type: text/plain, Size: 901 bytes --]

I'd like to run a bunch of services in a kind of sub-hierarchy under 
`/service/sub'; more precisely the service in `/service/sub' shall be something 
like runsvdir managing services in a directory `/service/sub/service'.

The naive approach was to let `/service/sub/run' be like this:

   #!/bin/sh
   exec runsvdir service

One problem with this is that bringing down all services in 
`/service/sub/services' involves something like

   sv o /service/sub ; sv h /service/sub

meaning that a simple removal of `/service/sub' is not enough, for this only 
will essentially result in a `sv x /service/sub' (according to the 
documentation of runit). As a solution, I came up with putting

   #!/bin/sh
   sv h .

into `control/t'. It seems to work, but I am not sure whether this is a good 
solution, in particular whether it is free of race-conditions.

Comments are welcome.

[-- Attachment #2: Type: application/pgp-signature, Size: 189 bytes --]

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2007-10-11 16:06 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-10-10 13:16 runsvdir under runsv Lasse Kliemann
2007-10-10 19:42 ` Joan Picanyol i Puig
2007-10-10 21:47   ` Lasse Kliemann
2007-10-11 12:50     ` Gerrit Pape
2007-10-11 16:06       ` Lasse Kliemann

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).