Add two new hook points: HOOK_SVC_RECONF and HOOK_RUNLEVEL_CHANGE.

These two new hooks run when SIGHUP is received and when changing
system runlevel.  The hooks are called when all services have been
stopped, just before starting up new/modified services.  Making it
the perfect hook for reconfiguring the system/hardware before new
services or modified services are started up again.

Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
This commit is contained in:
Joachim Nilsson committed 2015-05-31 22:07:46 +02:00
1 parent e83f4ab4bf
commit f5584ecc3c
3 files changed
+59 -8

No files matched your search

+8 -1
View File
@@ -41,11 +41,18 @@
* Predefined hook points for easier plugin debugging
*/
typedef enum {
/* Bootstrap hooks */
HOOK_ROOTFS_UP = 0,
HOOK_BASEFS_UP,
HOOK_NETWORK_UP,
HOOK_SYSTEM_UP,
HOOK_SVC_UP,
HOOK_SYSTEM_UP,
/* Runtime hooks */
HOOK_SVC_RECONF,
HOOK_RUNLEVEL_CHANGE,
/* Shutdown hooks */
HOOK_SHUTDOWN,
HOOK_MAX_NUM
} hook_point_t;