Documentation
¶
Overview ¶
Package pid1 installs the explicit PID-1 signal semantics (GAPI-DIV-027). The kernel suppresses default signal handling for pid 1 - SIGTERM to an init without a handler is silently dropped - so every signal this process answers is registered explicitly, with no implicit defaults.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Handlers ¶
type Handlers struct {
// Shutdown answers SIGTERM (graceful shutdown) and SIGINT
// (ctrl-alt-del via the kernel); the signal is passed through so
// the executor can distinguish them.
Shutdown func(os.Signal)
// Reload answers SIGHUP.
Reload func()
// Reap answers SIGCHLD - a kick for the subreaper's reap loop.
Reap func()
// Debug answers SIGUSR1 (rotate logs / debug dump).
Debug func()
// Emergency answers SIGUSR2 (emergency shell hook).
Emergency func()
}
Handlers holds the explicit semantics for each PID-1 signal. A nil handler absorbs its signal (registered but inert): PID 1 must never die to a default disposition.
Click to show internal directories.
Click to hide internal directories.