#!/bin/sh
# Startup script for ASPSeek's search daemon
#
# chkconfig: 2345 95 05
# description: ASPSeek is an Internet search engine

# Source function library.
. /etc/rc.d/init.d/functions

# This line is needed to cheat /etc/init.d/rc who expects action word

[ -f /usr/bin/searchd ] || exit 0

case "$1" in
  start)
		echo -n $"Starting ASPSeek searchd: " 
		daemon --user aspseek "/usr/bin/searchd -D"
		echo
		;;
	
  stop)
		echo -n $"Shutting down ASPSeek searchd "
		killproc searchd
		echo
		;;
	
	status)
		status searchd
		;;

	restart)
		$0 stop
		$0 start
		;;
	
  *)
		echo $"Usage: aspseek {start|stop|restart|status}"
		exit 1

esac

exit 0
