add redis cache and heroku config
This commit is contained in:
2
Gemfile
2
Gemfile
@@ -21,6 +21,8 @@ gem 'webpacker', '~> 5.0'
|
|||||||
gem 'turbolinks', '~> 5'
|
gem 'turbolinks', '~> 5'
|
||||||
# Use Redis adapter to run Action Cable in production
|
# Use Redis adapter to run Action Cable in production
|
||||||
gem 'redis', '~> 4.2.5'
|
gem 'redis', '~> 4.2.5'
|
||||||
|
# Ruby wrapper for hiredis (protocol serialization/deserialization and blocking I/O)
|
||||||
|
gem 'hiredis', '~> 0.6.3'
|
||||||
# Use Active Model has_secure_password
|
# Use Active Model has_secure_password
|
||||||
gem 'bcrypt', '~> 3.1.7'
|
gem 'bcrypt', '~> 3.1.7'
|
||||||
# Flexible authentication solution for Rails with Warden
|
# Flexible authentication solution for Rails with Warden
|
||||||
|
|||||||
@@ -129,6 +129,7 @@ GEM
|
|||||||
globalid (0.4.2)
|
globalid (0.4.2)
|
||||||
activesupport (>= 4.2.0)
|
activesupport (>= 4.2.0)
|
||||||
hashie (4.1.0)
|
hashie (4.1.0)
|
||||||
|
hiredis (0.6.3)
|
||||||
i18n (1.8.10)
|
i18n (1.8.10)
|
||||||
concurrent-ruby (~> 1.0)
|
concurrent-ruby (~> 1.0)
|
||||||
jaro_winkler (1.5.4)
|
jaro_winkler (1.5.4)
|
||||||
@@ -389,6 +390,7 @@ DEPENDENCIES
|
|||||||
database_cleaner
|
database_cleaner
|
||||||
devise (~> 4.7.3)
|
devise (~> 4.7.3)
|
||||||
dotenv-rails
|
dotenv-rails
|
||||||
|
hiredis (~> 0.6.3)
|
||||||
listen (~> 3.3)
|
listen (~> 3.3)
|
||||||
lograge (~> 0.11.2)
|
lograge (~> 0.11.2)
|
||||||
mobility (~> 1.1.1)
|
mobility (~> 1.1.1)
|
||||||
|
|||||||
2
Procfile
Normal file
2
Procfile
Normal file
@@ -0,0 +1,2 @@
|
|||||||
|
web: bundle exec rails server -p $PORT
|
||||||
|
worker: bundle exec sidekiq -t 25
|
||||||
@@ -56,7 +56,7 @@ Rails.application.configure do
|
|||||||
config.log_tags = [ :request_id ]
|
config.log_tags = [ :request_id ]
|
||||||
|
|
||||||
# Use a different cache store in production.
|
# Use a different cache store in production.
|
||||||
# config.cache_store = :mem_cache_store
|
config.cache_store = :redis_cache_store, { url: ENV['REDIS_URL'] }
|
||||||
|
|
||||||
# Use a real queuing backend for Active Job (and separate queues per environment).
|
# Use a real queuing backend for Active Job (and separate queues per environment).
|
||||||
# config.active_job.queue_adapter = :resque
|
# config.active_job.queue_adapter = :resque
|
||||||
|
|||||||
Reference in New Issue
Block a user