diff --git a/map-agent/files/etc/init.d/mapagent b/map-agent/files/etc/init.d/mapagent index deca28bdb..d92e058fd 100755 --- a/map-agent/files/etc/init.d/mapagent +++ b/map-agent/files/etc/init.d/mapagent @@ -6,6 +6,12 @@ STOP=20 USE_PROCD=1 start_service() { + config_load "mapagent" + + local enabled + config_get_bool enabled agent enabled 1 + [ "$enabled" -eq 0 ] && return 1 + procd_open_instance procd_set_param command "/usr/sbin/mapagent" "-d" procd_set_param respawn