supervision - discussion about system services, daemon supervision, init, runlevel management, and tools such as s6 and runit
 help / color / mirror / Atom feed
From: Jeff <sysinit@yandex.com>
To: supervision@List.skarnet.org
Subject: where is the right place to run s6-rc from ?
Date: Sun, 19 May 2019 23:23:35 +0200	[thread overview]
Message-ID: <20190519212334.GI4861@panda> (raw)


i wonder whether s6-rc (or any other service manager or startup script)
should be started from within the supervision tree directly as
service (dir) in the scandir ?

let us assume we created a service dir "rc" or so in the otherwise
unpopulated scandir (except required loggers).
it starts s6-rc (or another service manager) from its run script and
execs into "pause" or something similar that just pauses until killed.
that way it is possible to associate a log service with said "rc" service
and when "pause" exits the service manager can be called from the "finish"
script to bring down the other services correctly
(dunno if this script's output will be logged),
in this case shutdown would just mean to stop the "rc" service.

of course it would be more natural to make this very service run only
once via the "once" file. but i guess such "once" services cannot have
an associated logger, right ?

another hack would be to make this once service write its output to a
fifo that is read by another logging service, could this be s6-svscan's
own catch-all default logger ?

but when using such a catch-all logger to log s6-svscan's own output
there is no need for the "rc" service to have its own logger since
everything it outputs goes into this catch-all logger.

in case of a run-once service s6-rc would be called from s6-svscan's
signal handler scripts again to bring down services.

why not ? apparently a good idea ...



             reply	other threads:[~2019-05-19 21:23 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-05-19 21:23 Jeff [this message]
2019-05-19 23:12 ` Laurent Bercot

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20190519212334.GI4861@panda \
    --to=sysinit@yandex.com \
    --cc=supervision@List.skarnet.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).