Change various filenames.
The shell script previously used to launch the daemon is now called "initscript". The script files have had the ".js" extension removed from their names.
This commit is contained in:
parent
ff0814c7ac
commit
6457f18b36
7 changed files with 1264 additions and 1264 deletions
25
initscript
Normal file
25
initscript
Normal file
|
|
@ -0,0 +1,25 @@
|
|||
#!/bin/sh
|
||||
|
||||
NODE_PATH=/usr/lib/node_modules
|
||||
LOGFILE=/var/log/rlgwebd.log
|
||||
CTLSOCKET=/var/run/rlgwebd.sock
|
||||
RLGWEBDJS=./rlgwebd
|
||||
|
||||
export NODE_PATH
|
||||
|
||||
if [ $UID != 0 ]
|
||||
then
|
||||
echo "$0 needs to run as root." >&2
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [ $# -gt 0 ] && [ $1 = stop ]
|
||||
then
|
||||
socat "EXEC:echo quit" "$CTLSOCKET"
|
||||
else
|
||||
# Start
|
||||
setsid node "$RLGWEBDJS" </dev/null &>>$LOGFILE &
|
||||
fi
|
||||
|
||||
exit
|
||||
|
||||
Loading…
Add table
Add a link
Reference in a new issue