linkpi_firmware_history/rootfs/link/shell/init/service.sh

41 lines
735 B
Bash

. /link/shell/util/func.sh
jopen /link/config/service.json
if [ `jget telnet` == "true" ]; then
/usr/sbin/telnetd
fi
if [ `jget ssh` == "true" ] && ! procExists sshd; then
if [ ! -d /var/empty ];then
mkdir -p /var/empty
fi
chown root:root /var/empty
/usr/local/sbin/sshd
fi
if [ `jget php` == "true" ]; then
/usr/php/sbin/php-fpm -R -p /usr/php -c /usr/php/etc/php.ini
fi
if [ `jget nginx` == "true" ]; then
/usr/nginx/sbin/nginx -p /usr/nginx
fi
if [ `jget crond` == "true" ]; then
/usr/sbin/crond -d 8
fi
if [ `jget onvif` == "true" ]; then
/link/shell/onvif.sh
fi
if [ `jget ndi` == "true" ]; then
/link/shell/ndi.sh
fi
if [ `jget sls` == "true" ]; then
/link/bin/sls -c /link/config/sls.conf &
fi
/link/shell/ntp.sh &