Permalink
Browse files

ultrasphinx fixes

  • Loading branch information...
1 parent b4ceda8 commit da3262f57350b89804645ad75df78dac83cfde1d @vitaly vitaly committed Oct 25, 2009
Showing with 20 additions and 11 deletions.
  1. +1 −2 lib/vladify/thinking_sphinx.rb
  2. +19 −0 lib/vladify/ultrasphinx.rb
  3. +0 −9 lib/vladify/ultrasphynx.rb
@@ -1,6 +1,5 @@
namespace :remote do
namespace :sphinx do
- # rebuild - Stop Sphinx (if it's running), rebuild the indexes, and start Sphinx
%w/index start restart stop rebuild config/.each do |op|
desc "#{op} sphinx"
remote_task op.to_sym, :roles => :app do
@@ -9,5 +8,5 @@
end
end
end
-$configure_tasks << "remote:sphinx:config"
+$config_tasks << "remote:sphinx:config"
$restart_tasks << "remote:sphinx:rebuild"
@@ -0,0 +1,19 @@
+namespace :remote do
+ namespace :sphinx do
+ %w/start restart stop conf index/.each do |op|
+ desc "#{op} sphinx"
+ remote_task op.to_sym, :roles => :app do
+ run rake("us:#{op}")
+ end
+ end
+ task :config => "remote:sphinx:conf"
+
+ remote_task :rebuild, :roles => :app do
+ run rake("us:stop") rescue nil
+ run rake("us:index")
+ run rake("us:start")
+ end
+ end
+end
+$config_tasks << "remote:sphinx:config"
+$restart_tasks << "remote:sphinx:rebuild"
@@ -1,9 +0,0 @@
-namespace :remote do
- namespace :sphynx do
- remote_task :rebuild, :roles => :app do
- run rake("ultrasphinx:configure ultrasphinx:index")
- run rake("ultrasphinx:daemon:stop") rescue nil
- run rake("ultrasphinx:daemon:start")
- end
- end
-end

0 comments on commit da3262f

Please sign in to comment.