X-Git-Url: https://git.openstreetmap.org./rails.git/blobdiff_plain/dc2a2c8ebd1a11e4a64555fda22c6859a51defff..4bb9f96133e04872739b7f40034521b5b4de6a2d:/config/application.rb diff --git a/config/application.rb b/config/application.rb index 8ba628c8e..bee36fa2a 100644 --- a/config/application.rb +++ b/config/application.rb @@ -43,5 +43,10 @@ module OpenStreetMap # Don't eager load models when the database is offline config.paths["app/models"].skip_eager_load! if STATUS == :database_offline + + # Use memcached for caching if required + if defined?(MEMCACHE_SERVERS) + config.cache_store = :mem_cache_store, MEMCACHE_SERVERS, { :namespace => "rails:cache" } + end end end