Commit c8cb3ec0 authored by Jordan Sissel's avatar Jordan Sissel

- more fixes for the init script

- don't log prospecting, it's noisy.
parent 8a541d76
VERSION=0.1.0
VERSION=0.1.1
# By default, all dependencies (zeromq, etc) will be downloaded and installed
# locally. You can change this if you are deploying your own.
......
......@@ -21,19 +21,20 @@ DAEMON_ARGS="-config /opt/lumberjack/lumberjack.conf -spool-size 100 -log-to-sys
PIDFILE=/var/run/$NAME.pid
SCRIPTNAME=/etc/init.d/$NAME
COMMAND="cd /var/run; exec $DAEMON $DAEMON_ARGS"
[ -r /etc/default/$NAME ] && . /etc/default/$NAME
. /lib/init/vars.sh
. /lib/lsb/init-functions
do_start() {
# Skip if it's already running
start-stop-daemon --start --quiet --pidfile $PIDFILE \
--exec $DAEMON --test > /dev/null || return 1
start-stop-daemon --start --quiet --pidfile $PIDFILE --exec /bin/sh --test > /dev/null || return 1
cd /var/run
# Actually start it now.
start-stop-daemon --start --quiet --make-pidfile --background \
--pidfile $PIDFILE --exec $DAEMON -- $DAEMON_ARGS || return 2
--pidfile $PIDFILE --exec /bin/sh -- -c "$COMMAND" || return 2
}
do_stop()
......
......@@ -73,7 +73,7 @@ func resume_tracking(fileconfig FileConfig, fileinfo map[string]os.FileInfo, out
func prospector_scan(path string, fields map[string]string,
fileinfo map[string]os.FileInfo,
output chan *FileEvent) {
log.Printf("Prospecting %s\n", path)
//log.Printf("Prospecting %s\n", path)
// Evaluate the path as a wildcards/shell glob
matches, err := filepath.Glob(path)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment