Created
September 26, 2012 04:43
-
-
Save kbighorse/3786109 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# production.rb | |
... | |
config.middleware.use Rack::Cache | |
# Deflater is inserted here so gzipped assets aren't cached | |
config.middleware.insert_before Rack::Cache, Rack::Deflater | |
config.middleware.insert_after(Rack::Cache, Rack::ReverseProxy) do | |
reverse_proxy_options :preserve_host => true | |
reverse_proxy '/blog', 'http://bighorse.net' | |
end | |
# https://devcenter.heroku.com/articles/rack-cache-memcached-static-assets-rails31#configure-rails-cachestore | |
config.action_dispatch.rack_cache = { | |
:metastore => Dalli::Client.new, | |
:entitystore => 'file:tmp/cache/rack/body', | |
:allow_reload => false | |
} | |
... |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment