forked from davmac314/dinit
-
Notifications
You must be signed in to change notification settings - Fork 1
/
TODO
94 lines (86 loc) · 4.9 KB
/
TODO
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
For version 0.11.0:
-------------------
* [DONE] Show "activated" state in "dinitctl list" output
* [DONE] Service description sanity checks:
- Service 'type' defaults to 'internal'
- process-based service types require 'command' setting
- only scripted service supports 'stop-command'
- errors should also be reported by dinitcheck
* [DONE] dinitcheck should perform lint checks - do named files exist? etc
* [DONE] if service file exists but can't be opened, report suitable error rather than
"service not found" (dinit and dinitcheck)
* [DONE] successful "dinitctl enable servicename" should give feedback
* [DONE] change system socket location
* [DONE] process command properly (Linux)
* [DONE] Support --version on command line
* [DONE] remove "no-sigterm" and just have "term-signal" specify the signal, including "none".
For version 0.12.0:
-------------------
* Dinitctl command to get full status of a service.
- including reporting process launch failure reason
* better environment handling, way to restrict which variables get passed through
Note that "XXX=YYYY" settings on Linux kernel command line sometimes get set as environment
variables (and sometimes don't) even if the kernel should understand them (eg "pti=off",
but not "root=/dev/sda1").
For version 1.0 (release requirements):
---------------------------------------
* Service description parse errors should report line number
* Limit memory use by control connections. Currently clients can queue commands without limit.
* "triggered" service type: external process notifies Dinit when the service
has started. (maybe?)
- key thing is we want some way to eg mount filesystem once the disk comes up,
configure network when device comes up, etc, potentially relying an an external
tool/daemon.
* Be able to boot and shutdown Linux and FreeBSD (or OpenBSD).
Maybe for 1.0?
--------------
* Consider using mlockall (if system process).
* on shutdown, after a long interval with no activity, display information about
services we are waiting on (and/or, do this when prompted via ^C or C-A-D?)
* Documentation must be complete (mostly done; will need updates as other items are completed).
* Proper support for socket activation?
* Chaining of service process input/output?
For later (post 1.0):
---------------------
* Cgroups, jails support
* On linux when running with PID != 1, write PID to /proc/sys/kernel/cad_pid so
that we still receive SIGINT from ctrl+alt+del (must be done after /proc is
mounted, possibly could be left to a service script)
* Perhaps need a way to prevent script services from re-starting.
(eg there's no need to mount filesystems twice; there might be various other
system initialisations that can't or shouldn't really be "undone" and so do
not need to be re-done).
* Internationalisation
* A service can prevent shutdown/reboot by failing to stop. Maybe make
multiple CTRL-ALT-DEL presses (or ^C since that's more portable) commence
immediate shutdown (or launch a simple control interface).
* When we take down a service or tty session, it would be ideal if we could kill
the whole process tree, not just the leader process (need cgroups or pid
namespace or other mechanism).
* Allow logging tasks to memory (growing or circular buffer) and later
switching to disk logging (allows for filesystem mounted readonly on boot).
But perhaps this really the responsibility of another daemon.
* Allow running services with different resource limits, chroot, cgroups,
namespaces (pid/fs/uid), etc
* Support chaining service output to another process (logger) input; if the
service dies the file descriptor of its stdout isn't closed and is reassigned
when the service is restarted, so that minimal output is lost.
- even more, it would be nice if a single logger process could be responsible
for receiving output from multiple services. This would require some kind of
protocol for passing new output descriptors to the logger (for when a
service starts).
Even later / Maybe never:
-------------------------
* Support recognising /etc/init.d services automatically (as script services, with
no dependency management - or upstart compatible dependency management)
Also BSD's rc.d style scripts (PROVIDE, REQUIRE).
* Place some reasonable, soft limit on the number of services to be started
simultaneously, to prevent thrashing. Services that are taking a long time
to start don't count to the limit. Maybe use CPU/IO usage as a controlling
factor.
* Cron-like tasks (if started, they run a sub-task periodically. Stopping the
task will wait until the sub-task is complete).
* Allow to run services attached to virtual tty, allow connection to that tty (ala "screen").
* SystemD-like handling of filesystem mounts (see autofs documentation in kernel)
i.e. a mount point gets an autofs attached, and lazily gets mounted when accessed
(or is mounted in parallel). Probably put the functionality in a separate daemon.