-
-
Notifications
You must be signed in to change notification settings - Fork 2.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Init Script on CentOS 5.5 #324
Comments
Sorry... not sure how to format that better... |
Are you sure you want to execute Markdown Flavor of github is explained here: http://github.github.com/github-flavored-markdown/ ;) |
Yeah, I found that mistake in the init script and it started working. Now to debug a crash posted on another thread. Bug can be closed.
|
Not sure if this would be classified a bug or what... I have etherpad-lite working from the terminal just fine but when I try to execute use an init script in CentOS 5.5 I get a lot errors. Any suggestions on how to fix it?
Script here:
!/bin/sh
etherpad-lite - this script starts and stops the etherpad light daemon
chkconfig: - 64 36
Default-Start: 2 3 4 5
Default-Stop: 0 1 2 3 4 6
Required-Start:
description: etherpad lite is a collaboration editor
processname: node
config: /home/etherpad/etherpad-lite/settings.json
pidfile: none
lockfile: /var/lock/subsys/etherpad
Source function library.
. /etc/rc.d/init.d/functions
Source networking configuration.
. /etc/sysconfig/network
Check that networking is up.
[ "$NETWORKING" = "no" ] && exit 0
progname="Etherpad Lite"
path="/home/etherpad/etherpad-lite"
prog="/usr/bin/node"
parameter="server.js"
log="/var/log/etherpad/error.log"
conf="/home/etherpad/etherpad-lite/settings.json"
user="etherpad"
lockfile="/var/lock/subsys/etherpad"
logpath=$(dirname $log)
start() {
[ -x $prog ] || exit 5
[ -f $conf ] || exit 6
[ -d $logpath ] || mkdir $logpath
[ -f $log ] || touch $log
chown $user $logpath
chown $user $log
}
stop() {
echo -n $"Stopping $progname: "
killproc $prog
retval=$?
echo
[ $retval -eq 0 ] && rm -f $lockfile
return $retval
}
restart() {
stop
start
}
rh_status() {
status $prog
}
rh_status_q() {
rh_status >/dev/null 2>&1
}
case "$1" in
start)
rh_status_q && exit 0
$1
;;
stop)
rh_status_q || exit 0
$1
;;
restart)
$1
;;
status)
rh_status
;;
*)
echo $"Usage: $0 {start|stop|status|restart}"
exit 2
esac
Errors:
[root@xxxx etherpad-lite]#
node.js:201
throw e; // process.nextTick error, or 'error' event on first tick
^
Error: Cannot find module '/home/etherpad/etherpad-lite/server.js'
at Function._resolveFilename (module.js:334:11)
at Function._load (module.js:279:25)
at Array.0 (module.js:470:10)
at EventEmitter._tickCallback (node.js:192:40)
Is it a bad parameter handed off to node?
The text was updated successfully, but these errors were encountered: