Sha256: 416cd70230ecedfde047350129a9a4012d7f8914b71e979423b896e962f92198

Contents?: true

Size: 1.4 KB

Versions: 9

Compression:

Stored size: 1.4 KB

Contents

#!/bin/sh
#
# start/stop searchd server.

if ! [ -x /usr/local/bin/searchd ]; then
        exit 0
fi

case "$1" in
    start)
        echo -n "Starting sphinx searchd server:"
        echo -n " searchd" ; 
        /sbin/start-stop-daemon --start --quiet --pidfile /var/run/searchd.pid --chdir /etc --exec /usr/local/bin/searchd
        echo "."
        ;;
    stop)
        echo -n "Stopping sphinx searchd server:"
        echo -n " searchd" ; 
        /sbin/start-stop-daemon --stop --quiet --oknodo --pidfile /var/run/searchd.pid --exec /usr/local/bin/searchd
        echo "."
        ;;
    reload)
        echo -n "Reloading sphinx searchd server:"
        echo -n " searchd"
        /sbin/start-stop-daemon --stop --quiet --oknodo --pidfile /var/run/searchd.pid --signal 1
        echo "."
        ;;
    force-reload)
        $0 reload
        ;;
    reindex)
        cd /etc
        /usr/local/bin/indexer --rotate --quiet --all
        ;;
    restart)
        echo -n "Restarting sphinx searchd server:"
        echo -n " searchd"
        /sbin/start-stop-daemon --stop --quiet --oknodo --pidfile /var/run/searchd.pid --exec /usr/local/bin/searchd
        /sbin/start-stop-daemon --start --quiet --pidfile /var/run/searchd.pid --chdir /etc --exec  /usr/local/bin/searchd
        echo "."
        ;;
    *)
        echo "Usage: /etc/init.d/searchd {start|stop|reload|restart|reindex}"
        exit 1
        ;;
esac
exit 0

Version data entries

9 entries across 9 versions & 1 rubygems

Version Path
datamapper-0.2.0 plugins/can_has_sphinx/scripts/sphinx.sh
datamapper-0.2.1 plugins/can_has_sphinx/scripts/sphinx.sh
datamapper-0.2.2 plugins/can_has_sphinx/scripts/sphinx.sh
datamapper-0.2.3 plugins/can_has_sphinx/scripts/sphinx.sh
datamapper-0.3.2 plugins/can_has_sphinx/scripts/sphinx.sh
datamapper-0.3.1 plugins/can_has_sphinx/scripts/sphinx.sh
datamapper-0.2.4 plugins/can_has_sphinx/scripts/sphinx.sh
datamapper-0.2.5 plugins/can_has_sphinx/scripts/sphinx.sh
datamapper-0.3.0 plugins/can_has_sphinx/scripts/sphinx.sh