X-Git-Url: https://git.openstreetmap.org/rails.git/blobdiff_plain/dc2a2c8ebd1a11e4a64555fda22c6859a51defff..6671a934bf10ad202576d5ca0c1591cf2ef627f8:/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