lede/package/lean/shellinabox/files/shellinaboxd.init
2018-04-28 22:12:13 +08:00

25 lines
490 B
Bash
Executable File

#!/bin/sh /etc/rc.common
# Copyright (C) 2015 snqu.com
USE_PROCD=1
START=99
BIN=/usr/sbin/shellinaboxd
start_service() {
libssl=$(find /lib /usr/lib -name "libssl.so*" -type f)
if [ -n "$libssl" ];then
dir=$(dirname $libssl)
libssl=$(basename $libssl)
cd $dir
[ ! -f libssl.so ] && ln -s $libssl libssl.so
cd - > /dev/null
fi
procd_open_instance
procd_set_param command $BIN -u root -c /etc/shellinabox --css=/etc/shellinabox/white-on-black.css
procd_close_instance
}