From 19b9e1e2c3d621b5f9f2367980dae62648fe22fa Mon Sep 17 00:00:00 2001 From: Eugen Rochko Date: Sun, 5 Feb 2017 17:24:18 +0100 Subject: Preheat status cache --- config/environments/development.rb | 5 +++-- config/environments/production.rb | 2 +- 2 files changed, 4 insertions(+), 3 deletions(-) (limited to 'config') diff --git a/config/environments/development.rb b/config/environments/development.rb index 51cb43e5d..6157f20d3 100644 --- a/config/environments/development.rb +++ b/config/environments/development.rb @@ -20,11 +20,12 @@ Rails.application.configure do host: ENV['REDIS_HOST'] || 'localhost', port: ENV['REDIS_PORT'] || 6379, db: 0, - namespace: 'cache' + namespace: 'cache', + expires_in: 1.minute, } config.public_file_server.headers = { - 'Cache-Control' => 'public, max-age=172800' + 'Cache-Control' => 'public, max-age=172800', } else config.action_controller.perform_caching = false diff --git a/config/environments/production.rb b/config/environments/production.rb index eaddba522..62ea217ef 100644 --- a/config/environments/production.rb +++ b/config/environments/production.rb @@ -64,7 +64,7 @@ Rails.application.configure do password: ENV.fetch('REDIS_PASSWORD') { false }, db: 0, namespace: 'cache', - expires_in: 20.minutes + expires_in: 20.minutes, } # Enable serving of images, stylesheets, and JavaScripts from an asset server. -- cgit