Search sold edition,rake sunspot:solr:run. NewsBulletin.solr_search,NewsBulletin.solr_reindex. Not working

This commit is contained in:
Matthew K. Fu JuYuan committed 2012-06-20 14:50:51 +08:00
1 parent 8dd1ab32c1
commit cb17fe0825
46 files changed
+2597 -263

No files matched your search

+3 -2
View File
@@ -2,11 +2,12 @@ class BackupServer
@queue = :high
def self.perform()
CronMail.time_check("Going to backup Orbit").deliver
#CronMail.time_check("Going to backup Orbit").deliver
dbhost = Mongoid.config.database.connection.primary.join ':'
dbname = Mongoid.config.database.name
dbdirectory = "#{Rails.root}/tmp/#{dbname}-"+Time.now.strftime("%Y-%m-%d-%H-%M")
%x[mongodump -h dbhost -d dbname -o dbdirectory ]
%x[mongodump -h #{dbhost} -d #{dbname} -o #{dbdirectory} ]
# %x[touch #{Rails.root}/tmp/restart]
end
end