https://github.com/duzun/docker-sphinx
Sphinx Search for Docker
https://github.com/duzun/docker-sphinx
docker docker-image search sphinx
Last synced: about 2 months ago
JSON representation
Sphinx Search for Docker
- Host: GitHub
- URL: https://github.com/duzun/docker-sphinx
- Owner: duzun
- License: mit
- Created: 2018-07-15T21:17:26.000Z (almost 8 years ago)
- Default Branch: master
- Last Pushed: 2018-07-15T21:18:43.000Z (almost 8 years ago)
- Last Synced: 2025-03-30T11:34:28.225Z (about 1 year ago)
- Topics: docker, docker-image, search, sphinx
- Language: Shell
- Size: 15.6 KB
- Stars: 1
- Watchers: 2
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
Docker Sphinx
==========
Sphinx Search for Docker.
# Install and setup
```sh
sudo docker run -d -i -p "9312:9312" \
-v /etc/sphinx/conf.d:/etc/sphinx/conf.d \
-v /run/sphinx/:/run/sphinx/ \
-v /run/mysqld/:/run/mysqld/ \
--name 'sphinx' duzun/docker-sphinx
```
In `/etc/sphinx/conf.d` you could place some sphinx config files, one per database.
The name of the files in this folder should be '00_dbName.conf'.
You can override DB name with environment variables like 'DATABASE_DBNAME=my_db'.
In '00_dbName.conf' file you could use the `$DB` variable like this:
`sql_db = $DB`. See `/sphinx/etc/conf.d/*.conf.dist` for more examples.
You could also expose `/run/sphinx/searchd.sock` to host system to connect to sphinx daemon
through a socket.
It is also possible to use MySQL as a source of documents through sockets by exposing
`/run/mysqld/` folder to container.
This container defines a volume at `/var/lib/sphinx`, with `data` and `log` folders.
Also check `docker-composer.yml` file for an example of usage.