forked from e621ng/e621ng
Fix #4117: Use memcache for fragment caching.
This commit is contained in:
parent
ec0ae03aef
commit
725d6489d1
@ -2,9 +2,11 @@ Rails.application.configure do
|
||||
begin
|
||||
if Rails.env.test?
|
||||
config.cache_store = :memory_store, { size: 32.megabytes }
|
||||
config.action_controller.cache_store = :memory_store, { size: 32.megabytes }
|
||||
Rails.cache = ActiveSupport::Cache.lookup_store(Rails.application.config.cache_store)
|
||||
else
|
||||
config.cache_store = :dalli_store, Danbooru.config.memcached_servers, { namespace: Danbooru.config.safe_app_name }
|
||||
config.action_controller.cache_store = :dalli_store, Danbooru.config.memcached_servers, { namespace: Danbooru.config.safe_app_name }
|
||||
Rails.cache = ActiveSupport::Cache.lookup_store(Rails.application.config.cache_store)
|
||||
|
||||
Rails.cache.dalli.alive!
|
||||
|
Loading…
Reference in New Issue
Block a user