sphinx-setup.sh 407 Bytes
Newer Older
1
#!/bin/sh
2
SCRIPT=$(readlink -f "$0")
3 4
CWD=$(dirname "$SCRIPT")

Carsten Brandt committed
5
# make dir that is used in sphinx config
6 7 8
mkdir -p sphinx
sed -i s\~SPHINX_BASE_DIR~$PWD/sphinx~g $CWD/../sphinx/sphinx.conf

9 10 11
# Setup source database
mysql -D yiitest -u travis < $CWD/../sphinx/source.sql

12 13 14 15 16
# setup test Sphinx indexes:
indexer --config $CWD/../sphinx/sphinx.conf --all

# run searchd:
searchd --config $CWD/../sphinx/sphinx.conf