3 * provide a way to check configuration for errors (dinitcheck command) [DONE]
4 * Easy way to reload service description (including if service is running, where possible).
5 * report process launch failure reason (stage & errno) via dinitctl.
6 * "chain-to" can result in an unbreakable loop if the chain is circular. Chained services should not be
7 started during shutdown to prevent this (also avoids a race condition where the chained service is left
8 running when everything else has shutdown).
9 * Show "activated" state in "dinitctl list" output
13 * Service description sanity checks:
14 - Service type not specified
15 - maybe default to 'internal' if command not specified
16 - service command not specified
17 - errors should also be reported by dinitcheck
21 * Service description parse errors should report line number
22 * dinitcheck should perform lint checks - do named files exist? etc
23 * Limit memory use by control connections. Currently clients can queue commands without limit.
24 * Consider using mlockall (if system process).
25 * Dinitctl command to get full status of a service.
26 * "triggered" service type: external process notifies Dinit when the service
28 - key thing is we want some way to eg mount filesystem once the disk comes up,
29 configure network when device comes up, etc, potentially relying an an external
31 * on shutdown, after repeated intervals with no activity, display information
32 about services we are waiting on (or, do this when prompted via ^C or C-A-D).
33 * Documentation must be complete (see section below).
34 * Proper support for socket activation?
35 * Chaining of service process input/output?
36 * Be able to boot and shutdown Linux and FreeBSD (or OpenBSD).
40 * On linux when running with PID != 1, write PID to /proc/sys/kernel/cad_pid so
41 that we still receive SIGINT from ctrl+alt+del (must be done after /proc is
42 mounted, possibly could be left to a service script)
43 * Perhaps need a way to prevent script services from re-starting.
44 (eg there's no need to mount filesystems twice; there might be various other
45 system initialisations that can't or shouldn't really be "undone" and so do
46 not need to be re-done).
47 * Internationalisation
48 * A service can prevent shutdown/reboot by failing to stop. Maybe make
49 multiple CTRL-ALT-DEL presses (or ^C since that's more portable) commence
50 immediate shutdown (or launch a simple control interface).
51 * When we take down a service or tty session, it would be ideal if we could kill
52 the whole process tree, not just the leader process (need cgroups or pid
53 namespace or other mechanism).
54 * Allow logging tasks to memory (growing or circular buffer) and later
55 switching to disk logging (allows for filesystem mounted readonly on boot).
56 But perhaps this really the responsibility of another daemon.
57 * Allow running services with different resource limits, chroot, cgroups,
58 namespaces (pid/fs/uid), etc
59 * Support chaining service output to another process (logger) input; if the
60 service dies the file descriptor of its stdout isn't closed and is reassigned
61 when the service is restarted, so that minimal output is lost.
62 - even more, it would be nice if a single logger process could be responsible
63 for receiving output from multiple services. This would require some kind of
64 protocol for passing new output descriptors to the logger (for when a
67 Even later / Maybe never:
68 -------------------------
69 * Support recognising /etc/init.d services automatically (as script services, with
70 no dependency management - or upstart compatible dependency management)
71 Also BSD's rc.d style scripts (PROVIDE, REQUIRE).
72 * Place some reasonable, soft limit on the number of services to be started
73 simultaneously, to prevent thrashing. Services that are taking a long time
74 to start don't count to the limit. Maybe use CPU/IO usage as a controlling
76 * Cron-like tasks (if started, they run a sub-task periodically. Stopping the
77 task will wait until the sub-task is complete).
78 * Allow to run services attached to virtual tty, allow connection to that tty (ala "screen").
79 * SystemD-like handling of filesystem mounts (see autofs documentation in kernel)
80 i.e. a mount point gets an autofs attached, and lazily gets mounted when accessed
81 (or is mounted in parallel). Probably put the functionality in a separate daemon.
86 * Design philosophy/rationale document
87 * More system integration documentation?