lib/tasks/server.rake in picky-0.0.5 vs lib/tasks/server.rake in picky-0.0.6
- old
+ new
@@ -1,23 +1,23 @@
# TODO This file needs some love.
#
namespace :server do
def chdir_to_root
- Dir.chdir SEARCH_ROOT
+ Dir.chdir PICKY_ROOT
end
def current_pid
- pid = `cat #{File.join(SEARCH_ROOT, 'tmp/pids/unicorn.pid')}`
+ pid = `cat #{File.join(PICKY_ROOT, 'tmp/pids/unicorn.pid')}`
pid.blank? ? nil : pid.chomp
end
desc "Start the unicorns. Weheee!"
task :start => :framework do
chdir_to_root
# Rake::Task[:"solr:start"].invoke # TODO Move to better place.
- daemonize = SEARCH_ENVIRONMENT == 'production' ? '-D' : ''
- command = "export SEARCH_ENV=#{SEARCH_ENVIRONMENT}; unicorn -c unicorn.ru #{daemonize}".strip
+ daemonize = PICKY_ENVIRONMENT == 'production' ? '-D' : ''
+ command = "export PICKY_ENV=#{PICKY_ENVIRONMENT}; unicorn -c unicorn.ru #{daemonize}".strip
puts "Running \`#{command}\`."
exec command
end
desc "Stop the unicorns. Blam!"