Allow tty's to always respawn, no max restart count

This patch adds a `respawn` flag for services and ttys, always set for
ttys, that allows bypassing the crash/restart counter and immediately
restart a 'crashing' service.

For tty type services this is the expected behavior, but for regular
services it is not.  That is why `respawn` flags is not advertised in
the docs.

Signed-off-by: Joachim Wiberg <troglobit@gmail.com>
This commit is contained in:
Joachim Wiberg committed 2021-05-31 06:29:11 +02:00
1 parent ed9590aef1
commit a19b82ea5f
2 files changed
+15 -2

No files matched your search

+1
View File
@@ -127,6 +127,7 @@ typedef struct svc {
/* Counters */
char once; /* run/task, (at least) once per runlevel */
char respawn; /* ttys, or services with `respawn`, never increment restart_cnt */
const char restart_cnt; /* Incremented for each restart by service monitor. */
union {