X-Git-Url: http://git.openwrt.org/?a=blobdiff_plain;f=package%2Fbase-files%2Ffiles%2Fetc%2Frc.common;h=d7473038444cb1b6b4f58f408e3cbd2bfdd94f4b;hb=09c41ea6792a86cfcacb13f6727f5049c3f87cd6;hp=e950ec209dc6d2cbdfc9ab6ee996e82a33d7eb4e;hpb=b9017384cae7bbc47186fdf35a80207844876a0d;p=openwrt%2Fstaging%2Fdedeckeh.git diff --git a/package/base-files/files/etc/rc.common b/package/base-files/files/etc/rc.common index e950ec209d..d747303844 100755 --- a/package/base-files/files/etc/rc.common +++ b/package/base-files/files/etc/rc.common @@ -126,6 +126,7 @@ extra_command "enabled" "Check if service is started on boot" extra_command "running" "Check if service is running" extra_command "status" "Service status" extra_command "trace" "Start with syscall trace" + extra_command "info" "Dump procd service info" . $IPKG_INSTROOT/lib/functions/procd.sh basescript=$(readlink "$initscript") @@ -149,6 +150,13 @@ extra_command "enabled" "Check if service is started on boot" start "$@" } + info() { + json_init + json_add_string name "$(basename ${basescript:-$initscript})" + json_add_boolean verbose "1" + _procd_ubus_call list + } + stop() { procd_lock stop_service "$@"