From e26fb8d5cc0e9b018c0d0cd8d6b092e13268f40b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Juanjo=20Baz=C3=A1n?= Date: Thu, 24 Oct 2024 19:23:07 +0200 Subject: [PATCH] Configure Sidekiq->SSL->Redis https://devcenter.heroku.com/articles/connecting-heroku-redis#connecting-from-sidekiq --- app/lib/workers.rb | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/app/lib/workers.rb b/app/lib/workers.rb index d435375c..3b8cebf6 100644 --- a/app/lib/workers.rb +++ b/app/lib/workers.rb @@ -1,4 +1,17 @@ require 'sidekiq' +Sidekiq.configure_server do |config| + config.redis = { + url: ENV["REDIS_URL"], + ssl_params: { verify_mode: OpenSSL::SSL::VERIFY_NONE } + } +end +Sidekiq.configure_client do |config| + config.redis = { + url: ENV["REDIS_URL"], + ssl_params: { verify_mode: OpenSSL::SSL::VERIFY_NONE } + } +end + require "#{File.expand_path '../..', __FILE__}/workers/buffy_worker.rb" Dir["#{File.expand_path '../..', __FILE__}/workers/**/*.rb"].sort.each { |f| require f } \ No newline at end of file