想在 coding.net 上用 sidekiq
部署命令:bundle exec rake db:migrate && bundle exec sidekiq && bundle exec rails s -p $PORT
日志报错信息
2015-06-20T10:16:14.76+0800 [App/0] OUT 2015-06-20T02:16:14.764Z 53 TID-oulr82s2s INFO: Booting Sidekiq 3.3.4 with redis options {:url=>"redis://96a45941-1764-43cd-9038-3cdc7ad27d50:[email protected]:5372/12"}
2015-06-20T10:16:15.71+0800 [App/0] OUT 2015-06-20T02:16:15.712Z 53 TID-oulr82s2s INFO: Running in ruby 2.0.0p481 (2014-05-08 revision 45883) [x86_64-linux]
2015-06-20T10:16:15.93+0800 [App/0] OUT 2015-06-20T02:16:15.712Z 53 TID-oulr82s2s INFO: See LICENSE and the LGPL-3.0 for licensing details.
2015-06-20T10:16:15.93+0800 [App/0] OUT 2015-06-20T02:16:15.712Z 53 TID-oulr82s2s INFO: Upgrade to Sidekiq Pro for more features and support: http://sidekiq.org/pro
2015-06-20T10:16:15.93+0800 [App/0] OUT 2015-06-20T02:16:15.713Z 53 TID-oulr82s2s INFO: Starting processing, hit Ctrl-C to stop
2015-06-20T10:17:09.69+0800 [DEA] OUT Instance (index 0) failed to start accepting connections
2015-06-20T10:17:09.70+0800 [API] OUT App instance exited with guid 7ba44f26-71c6-4f21-a649-bb721682aa6e payload: {"cc_partition"=>"default", "droplet"=>"7ba44f26-71c6-4f21-a649-bb721682aa6e", "version"=>"fde69028-912e-4385-88b2-78c0bace1256", "instance"=>"d89477ad978e4940aa56396990a47ad5", "index"=>0, "reason"=>"CRASHED", "exit_status"=>-1, "exit_description"=>"failed to accept connections within health check timeout", "crash_timestamp"=>1434766629}
2015-06-20T10:17:18.12+0800 [DEA] OUT Removing crash for app with id 7ba44f26-71c6-4f21-a649-bb721682aa6e
2015-06-20T10:17:18.12+0800 [DEA] OUT Stopping app instance (index 0) with guid 7ba44f26-71c6-4f21-a649-bb721682aa6e
2015-06-20T10:17:18.12+0800 [DEA] OUT Stopped app instance (index 0) with guid 7ba44f26-71c6-4f21-a649-bb721682aa6e
2015-06-20T10:18:04.04+0800 [DEA] OUT Starting app instance (index 0) with guid 7ba44f26-71c6-4f21-a649-bb721682aa6e
接下来就是无限循环这个报错信息 sidekiq 的配置
require 'sidekiq'
redis_config = YAML.load_file("#{Rails.root}/config/redis.yml")[Rails.env]
sidekiq_url = "redis://#{redis_config['name']}:#{redis_config['password']}@#{redis_config['host']}:#{redis_config['port']}"
Sidekiq.configure_client do |config|
config.redis = { url: sidekiq_url }
end
Sidekiq.configure_server do |config|
config.redis = { url: sidekiq_url }
end
谁能帮忙解决下,不胜感激