File tree Expand file tree Collapse file tree 3 files changed +6
-0
lines changed Expand file tree Collapse file tree 3 files changed +6
-0
lines changed Original file line number Diff line number Diff line change @@ -178,5 +178,6 @@ group :production do
178
178
gem 'puma'
179
179
gem 'puma_worker_killer'
180
180
gem 'rack-attack'
181
+ gem 'rack-cache'
181
182
gem 'rails_12factor'
182
183
end
Original file line number Diff line number Diff line change @@ -685,6 +685,7 @@ DEPENDENCIES
685
685
querystring
686
686
quiet_assets
687
687
rack-attack
688
+ rack-cache
688
689
rails (~> 3.2 )
689
690
rails-erd
690
691
rails_12factor
Original file line number Diff line number Diff line change 28
28
config . assets . digest = true
29
29
config . static_cache_control = 'public, max-age=31536000'
30
30
config . host = ENV [ 'HOST_DOMAIN' ]
31
+ config . action_dispatch . rack_cache = true
32
+ client = Dalli ::Client . new ( ENV [ 'MEMCACHIER_SERVERS' ] , value_max_bytes : 10_485_760 )
33
+ config . action_dispatch . rack_cache = { metastore : client , entitystore : client }
34
+
31
35
config . middleware . use ( 'Rack::Deflater' )
32
36
config . middleware . use ( 'Rack::Attack' )
33
37
end
You can’t perform that action at this time.
0 commit comments