allow <environment>-local.rb to overwrite cache configuration
so that memory_store can be used in development Change-Id: Iaa3badc732b32c0f6970a969b172aa76190e08f7 Reviewed-on: https://gerrit.instructure.com/5882 Reviewed-by: JT Olds <jt@instructure.com> Tested-by: Hudson <hudson@instructure.com>
This commit is contained in:
parent
593f36991b
commit
23edefc404
|
@ -27,14 +27,14 @@ config.to_prepare do
|
|||
Canvas.dynamic_finder_type_cast_error = :raise
|
||||
end
|
||||
|
||||
# eval <env>-local.rb if it exists
|
||||
Dir[File.dirname(__FILE__) + "/" + File.basename(__FILE__, ".rb") + "-*.rb"].each { |localfile| eval(File.new(localfile).read) }
|
||||
|
||||
# initialize cache store
|
||||
# this needs to happen in each environment config file, rather than a
|
||||
# config/initializer/* file, to allow Rails' full initialization of the cache
|
||||
# to take place, including middleware inserts and such.
|
||||
config.cache_store = Canvas.cache_store_config
|
||||
|
||||
# eval <env>-local.rb if it exists
|
||||
Dir[File.dirname(__FILE__) + "/" + File.basename(__FILE__, ".rb") + "-*.rb"].each { |localfile| eval(File.new(localfile).read) }
|
||||
|
||||
# allow debugging only in development environment by default
|
||||
require "ruby-debug"
|
||||
|
|
|
@ -15,11 +15,11 @@ config.action_view.cache_template_loading = true
|
|||
# Disable delivery errors, bad email addresses will be ignored
|
||||
# config.action_mailer.raise_delivery_errors = false
|
||||
|
||||
# eval <env>-local.rb if it exists
|
||||
Dir[File.dirname(__FILE__) + "/" + File.basename(__FILE__, ".rb") + "-*.rb"].each { |localfile| eval(File.new(localfile).read) }
|
||||
|
||||
# initialize cache store
|
||||
# this needs to happen in each environment config file, rather than a
|
||||
# config/initializer/* file, to allow Rails' full initialization of the cache
|
||||
# to take place, including middleware inserts and such.
|
||||
config.cache_store = Canvas.cache_store_config
|
||||
|
||||
# eval <env>-local.rb if it exists
|
||||
Dir[File.dirname(__FILE__) + "/" + File.basename(__FILE__, ".rb") + "-*.rb"].each { |localfile| eval(File.new(localfile).read) }
|
||||
|
|
Loading…
Reference in New Issue