Skip to content
This repository was archived by the owner on May 22, 2024. It is now read-only.

jc21/docker-sphinxsearch

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Sphinx Search

Sphinx Stars Pulls

Sphinx Search running on Centos 7

Due to the way Sphinx operates, you need to follow these steps:

  • Define your Sphinx Configuration - sphinx.conf
  • Get Sphinx to build the Indexes
  • Run the Server
  • Rotate the Indexes periodically

Docker Compose Example

version: "2"
services:
  sphinx:
    image: jc21/sphinxsearch
    ports:
      - 9306:9306
      - 9312:9312
    volumes:
      - "./sphinx.conf:/etc/sphinx/sphinx.conf"
      - "./data:/var/lib/sphinx"

Creating the Indexes

With docker-compose:

docker-compose run --rm sphinx indexer --all

With docker vanilla:

docker run --rm -it \
    -v /path/to/sphinx.conf:/etc/sphinx/sphinx.conf \
    -v /path/to/data:/var/lib/sphinx \
    jc21/sphinxsearch \
    indexer --all

Running the Sphinx Search Server

With docker-compose:

docker-compose up -d

With docker vanilla:

docker run --detach \
    --name sphinxsearch \
    -p 9306:9306 \
    -p 9312:9312 \
    -v /path/to/sphinx.conf:/etc/sphinx/sphinx.conf \
    -v /path/to/data:/var/lib/sphinx \
    jc21/sphinxsearch

Rotating the Indexes

The docker container must be running for rotating to work.

With docker-compose:

docker-compose exec sphinx indexer --all --rotate 

With docker vanilla (assuming your container name is "sphinxsearch"):

docker exec -it sphinxsearch indexer --all --rotate

About

Docker container for Sphinx Search

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published