Skip to content

Commit

Permalink
Add heroku redis ssl configs
Browse files Browse the repository at this point in the history
  • Loading branch information
imustafin committed Oct 31, 2024
1 parent be98afd commit d4a6092
Showing 1 changed file with 17 additions and 0 deletions.
17 changes: 17 additions & 0 deletions config/initializers/heroku_redis.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# Redis on Heroku needs no ssl
# https://devcenter.heroku.com/articles/connecting-heroku-redis#connecting-in-ruby
$redis = Redis.new(url: ENV["REDIS_URL"], ssl_params: { verify_mode: OpenSSL::SSL::VERIFY_NONE })

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

0 comments on commit d4a6092

Please sign in to comment.