946ae33596
- system page to new button names "HOTSPOT ON/OFF" - added some linux files to make use of them as example files in "/usr/local/sbin/"
27 lines
518 B
Bash
27 lines
518 B
Bash
#!/bin/bash
|
|
|
|
if [ "$EUID" -ne 0 ]
|
|
then echo "root privileges needed. Aborting."
|
|
exit 1
|
|
fi
|
|
|
|
case "$1" in
|
|
on)
|
|
systemctl start mmdvmhost.timer
|
|
systemctl start mmdvmhost.service
|
|
/usr/local/sbin/dashboard on
|
|
;;
|
|
|
|
off)
|
|
systemctl stop mmdvmhost.timer
|
|
systemctl stop mmdvmhost.service
|
|
/usr/local/sbin/dashboard off
|
|
;;
|
|
help)
|
|
echo "$(basename $0)"
|
|
echo " Enable or disable systemd services for MMDVMHost"
|
|
;;
|
|
*)
|
|
echo "usage: $(basename $0) [ on | off ]"
|
|
exit 1
|
|
esac
|