Reputation: 43949
I am having two small apps having search in it. They are completly two different apps with different database etc.
Now the issue is coming up pid file.At a time only on application is searching cause when I do
rake ts:start
on one it says another instance is already running. How can I change this so that sphinx keep running for both the applications. I am using Capistrano for development.
Structure is something like this:
/home/me/my_app_1/production/current
/home/me/my_app_2/production/current
Upvotes: 2
Views: 581
Reputation: 8954
In both apps you have to create a config/sphinx.yml
which can contain various configuration variables and one of them allows you to specify the port of the sphinx server. When you define the port manually in one app like this:
development:
port: 9313
test:
port: 9314
production:
port: 9316
and in the other:
development:
port: 9317
test:
port: 9318
production:
port: 9319
Then call rake ts:rebuild
in both applications. Thinking sphinx will generate new config files for sphinx that setup different sphinx instances for each app and each environment in the app.
Upvotes: 4