Browse Source

CLDC-2831 Update profiler storage (#2514)

* Update profiler storage

* lint
pull/2511/head
kosiakkatrina 5 months ago committed by GitHub
parent
commit
2203577fee
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
  1. 11
      config/initializers/mini_profiler.rb

11
config/initializers/mini_profiler.rb

@ -0,0 +1,11 @@
require "configuration/configuration_service"
require "configuration/env_configuration_service"
# set RedisStore
if Rails.env.staging?
configuration_service = Configuration::EnvConfigurationService.new
redis_url = configuration_service.redis_uris.to_a[0][1]
Rack::MiniProfiler.config.storage_options = { url: redis_url }
Rack::MiniProfiler.config.storage = Rack::MiniProfiler::RedisStore
end
Loading…
Cancel
Save