fix: Define service manager for OpenWrt

OpenWrt uses `procd` as a service manager (see: <https://openwrt.org/docs/techref/procd>).

This fixes exception "Unknown service manager" returned by BOOT-5104 test.
This commit is contained in:
macie 2025-03-23 20:39:16 +01:00
parent 174152ef24
commit 3331bff914
No known key found for this signature in database

View file

@ -65,6 +65,7 @@
# runit - Used by Artix, Devuan, Dragora and Void
# systemd - Common option with more Linux distros implementing it
# upstart - Used by Debian/Ubuntu
# procd - Used by OpenWrt
Register --test-no BOOT-5104 --weight L --network NO --category security --description "Determine service manager"
if [ ${SKIPTEST} -eq 0 ]; then
BOOT_LOADER_SEARCHED=1
@ -114,6 +115,9 @@
openrc-init)
SERVICE_MANAGER="openrc"
;;
procd)
SERVICE_MANAGER="procd"
;;
*)
CONTAINS_SYSTEMD=$(echo ${SHORTNAME} | ${GREPBINARY} "systemd")
if [ -n "${CONTAINS_SYSTEMD}" ]; then