diff options
Diffstat (limited to 'package/openct/files')
-rw-r--r-- | package/openct/files/openct.init | 28 | ||||
-rw-r--r-- | package/openct/files/openct.postinst | 3 |
2 files changed, 31 insertions, 0 deletions
diff --git a/package/openct/files/openct.init b/package/openct/files/openct.init new file mode 100644 index 000000000..5f4b93c16 --- /dev/null +++ b/package/openct/files/openct.init @@ -0,0 +1,28 @@ +#!/bin/sh +#PKG openct +#INIT 60 + +. /etc/rc.conf + +case $1 in +autostop) ;; +autostart) + test x"${openct:-NO}" = x"NO" && exit 0 + exec sh $0 start + ;; +start) + test -d /var/run/openct || mkdir -p /var/run/openct + /usr/sbin/openct-control init + ;; +stop) + /usr/sbin/openct-control shutdown + ;; +restart) + sh $0 stop + sh $0 start + ;; +*) + echo "usage: $0 {start | stop | restart}" + exit 1 +esac +exit $? diff --git a/package/openct/files/openct.postinst b/package/openct/files/openct.postinst new file mode 100644 index 000000000..c02a18c6d --- /dev/null +++ b/package/openct/files/openct.postinst @@ -0,0 +1,3 @@ +#!/bin/sh +. $IPKG_INSTROOT/etc/functions.sh +add_rcconf openct openct NO |