diff --git a/config/application.rb b/config/application.rb index 43a939be..da0e4016 100644 --- a/config/application.rb +++ b/config/application.rb @@ -22,7 +22,7 @@ module AssetManager class Application < Rails::Application # Initialize configuration defaults for originally generated Rails version. - config.load_defaults 7.2 + config.load_defaults 8.0 # Please, add to the `ignore` list any other `lib` subdirectories that do # not contain `.rb` files, or that should not be reloaded or eager loaded. @@ -47,6 +47,19 @@ class Application < Rails::Application # Disable Rack::Cache config.action_dispatch.rack_cache = nil + # ActionDispatch strict freshness + # + # Configures whether the ActionDispatch::ETag middleware should prefer the + # ETag header over the Last-Modified header when both are present in the + # response. + # + # If set to true, when both headers are present only the ETag is considered + # as specified by RFC 7232 section 6. + # + # If set to false, when both headers are present, both headers are checked + # and both need to match for the response to be considered fresh. + config.action_dispatch.strict_freshness = false + config.assets.prefix = "/asset-manager" unless Rails.application.config_for(:secrets).jwt_auth_secret