From db04e3b04b41596c6199c6136faebbafb16f1b34 Mon Sep 17 00:00:00 2001 From: rhymes Date: Mon, 11 Nov 2019 20:45:52 +0100 Subject: [PATCH] Add redis-rails gem and REDIS_SESSIONS_URL env variable (#4789) [deploy] --- Envfile | 5 ++++- Gemfile | 1 + Gemfile.lock | 17 +++++++++++++++++ 3 files changed, 22 insertions(+), 1 deletion(-) diff --git a/Envfile b/Envfile index 1b8832a61..9dd4d2b0a 100644 --- a/Envfile +++ b/Envfile @@ -32,9 +32,12 @@ variable :RACK_TIMEOUT_SERVICE_TIMEOUT, :Integer, default: 100_000 # Production related config that can be ignored variable :DEPLOYMENT_SIGNATURE, :String, default: "Optional" -# For Redis storage +# Redis caching storage variable :REDIS_URL, :String, default: "redis://localhost:6379" +# Redis sessions storage +variable :REDIS_SESSIONS_URL, :String, default: "redis://localhost:6379" + ################################################ ############## 3rd Party Services ############## ################################################ diff --git a/Gemfile b/Gemfile index bd3480267..df353f5b8 100644 --- a/Gemfile +++ b/Gemfile @@ -77,6 +77,7 @@ gem "rails-settings-cached", ">= 2.1.1" # Settings plugin for Rails that makes m gem "recaptcha", "~> 5.2", require: "recaptcha/rails" # Helpers for the reCAPTCHA API gem "redcarpet", "~> 3.5" # A fast, safe and extensible Markdown to (X)HTML parser gem "redis", "~> 4.1.3" # Redis ruby client +gem "redis-rails", "~> 5.0.2" # Redis for Ruby on Rails gem "reverse_markdown", "~> 1.3" # Map simple html back into markdown gem "rolify", "~> 5.2" # Very simple Roles library gem "rouge", "~> 3.12" # A pure-ruby code highlighter diff --git a/Gemfile.lock b/Gemfile.lock index b32dfb349..652184839 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -615,6 +615,22 @@ GEM json redcarpet (3.5.0) redis (4.1.3) + redis-actionpack (5.1.0) + actionpack (>= 4.0, < 7) + redis-rack (>= 1, < 3) + redis-store (>= 1.1.0, < 2) + redis-activesupport (5.2.0) + activesupport (>= 3, < 7) + redis-store (>= 1.3, < 2) + redis-rack (2.0.6) + rack (>= 1.5, < 3) + redis-store (>= 1.2, < 2) + redis-rails (5.0.2) + redis-actionpack (>= 5.0, < 6) + redis-activesupport (>= 5.0, < 6) + redis-store (>= 1.2, < 2) + redis-store (1.8.1) + redis (>= 4, < 5) regexp_parser (1.6.0) representable (3.0.4) declarative (< 0.1.0) @@ -949,6 +965,7 @@ DEPENDENCIES recaptcha (~> 5.2) redcarpet (~> 3.5) redis (~> 4.1.3) + redis-rails (~> 5.0.2) reverse_markdown (~> 1.3) rolify (~> 5.2) rouge (~> 3.12)