forked from QuinnDamerell/OctoPrint-OctoEverywhere
-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathS99octoeverywhere
38 lines (35 loc) · 1.14 KB
/
S99octoeverywhere
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
#!/bin/sh
# System startup script for Octoeverywhere Klipper plugin
### BEGIN INIT INFO
# Provides: octoeverywhere
# Required-Start: $local_fs S56moonraker
# Required-Stop:
# Default-Start: 2 3 4 5
# Default-Stop: 0 1 6
# Short-Description: Octoeverywhere daemon
# Description: Starts the Octoeverywhere daemon.
### END INIT INFO
PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
DESC="octoeverywhere daemon"
NAME="octoeverywhere"
PIDFILE=/var/run/octoeverywhere.pid
case "$1" in
start) echo "Starting Octoeverywhere"
start-stop-daemon --start --quiet --exec /usr/data/startup_script.sh \
--background --pidfile $PIDFILE --make-pidfile \
--chuid root --user root \
# -- $OCTO_ARGS
;;
stop) echo "Not implemented"
;;
restart) log_daemon_msg "Restarting" $NAME
$0 stop
$0 start
;;
reload|force-reload)
echo "Reloading configuration not supported"
;;
*) echo "Usage: /etc/init.d/octoeverywhere {start|stop|status|restart|reload|force-reload}"
exit 2
;;
esac