This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
production: | |
adapter: mysql | |
database: staging | |
username: root | |
password: password | |
host: localhost | |
socket: /var/lib/mysql/mysql.sock |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Following schedule is set on Intialization. config/initializers | |
jt = ATask.find(:first) | |
dmt = BTask.find(:first) | |
Resque.schedule = {"ASchedule" => { | |
"cron" => "0 */#{jt.hours} * * *", | |
"class" => A, | |
"args" => "", | |
"description" => "Job for A" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Cookbook Name:: resque | |
# Recipe:: default | |
# | |
#if ['solo', 'util'].include?(node[:instance_role]) | |
if ['solo', 'app_master', 'app', 'util'].include?(node[:instance_role]) | |
execute "install resque gem" do | |
command "gem install resque redis redis-namespace yajl-ruby -r" | |
not_if { "gem list | grep resque" } | |
end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[root@localhost foundation3]# ey recipes upload -e staging | |
Recipes uploaded successfully for staging | |
[root@localhost foundation3]# ey recipes apply -e staging | |
Uploaded recipes started for staging | |
[root@localhost foundation3]# ey deploy -e staging | |
Connecting to the server... | |
Beginning deploy for 'foundation3' in 'staging' on server... | |
~> Deploying revision 76bb098... resque settings update | |
~> Pushing code to all servers | |
~> Starting full deploy |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
domU-12-31-39-13-BD-B3 deploy # pwd | |
/data/foundation3/current/deploy | |
domU-12-31-39-13-BD-B3 deploy # ls | |
after_restart.rb before_migrate.rb | |
domU-12-31-39-13-BD-B3 deploy # |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{"exception":"NameError","payload":{"args":[376],"class":"Merge"},"worker":"domU-12-31-39-13-BC-93:15363:upload_q,merge_q","backtrace":["/usr/lib/ruby/gems/1.8/gems/activesupport-2.3.5/lib/active_support/dependencies.rb:443:in `load_missing_constant'","/usr/lib/ruby/gems/1.8/gems/activesupport-2.3.5/lib/active_support/dependencies.rb:80:in `const_missing'","/usr/lib/ruby/gems/1.8/gems/activesupport-2.3.5/lib/active_support/dependencies.rb:92:in `const_missing'","/usr/lib/ruby/gems/1.8/gems/resque-1.9.10/lib/resque/helpers.rb:58:in `const_get'","/usr/lib/ruby/gems/1.8/gems/resque-1.9.10/lib/resque/helpers.rb:58:in `constantize'","/usr/lib/ruby/gems/1.8/gems/resque-1.9.10/lib/resque/helpers.rb:57:in `each'","/usr/lib/ruby/gems/1.8/gems/resque-1.9.10/lib/resque/helpers.rb:57:in `constantize'","/usr/lib/ruby/gems/1.8/gems/resque-1.9.10/lib/resque/job.rb:170:in `payload_class'","/usr/lib/ruby/gems/1.8/gems/resque-1.9.10/lib/resque/job.rb:107:in `perform'","/usr/lib/ruby/gems/1.8/gems/resque-1.9.10/lib/resque/worke |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
cache_settings = YAML.load_file("#{RAILS_ROOT}/config/memcached.yml") | |
config.cache_store = :mem_cache_store, cache_settings['servers'], cache_settings | |
config.action_controller.session = { | |
:memcache_server => (Rails.env == 'defaults') ? cache_settings['session_servers'] : cache_settings['servers'], | |
:namespace => "defaults:session", | |
:expire_after => 5.days | |
} | |
config.action_controller.session_store = :mem_cache_store |