From 006abee23dd8a0d393c41225a91119391f6c3454 Mon Sep 17 00:00:00 2001 From: Pau Perez Date: Mon, 18 Jan 2021 11:59:57 +0100 Subject: [PATCH] Update old setting to serve static assets Fixes the following deprecation warning: ``` DEPRECATION WARNING: The configuration option `config.serve_static_assets` has been renamed to `config.serve_static_files` to clarify its role (it merely enables serving everything in the `public` folder and is unrelated to the asset pipeline). The `serve_ static_assets` alias will be removed in Rails 5.0. Please migrate your configuration files accordingly. (called from block in at /usr/src/app/config/environments/test.rb:13) ``` --- config/environments/production.rb | 2 +- config/environments/staging.rb | 2 +- config/environments/test.rb | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/config/environments/production.rb b/config/environments/production.rb index 7541e78ae1..695f61a0a1 100644 --- a/config/environments/production.rb +++ b/config/environments/production.rb @@ -11,7 +11,7 @@ Openfoodnetwork::Application.configure do config.action_controller.perform_caching = true # Disable Rails's static asset server (Apache or nginx will already do this) - config.serve_static_assets = false + config.serve_static_files = false # Compress JavaScripts and CSS config.assets.compress = true diff --git a/config/environments/staging.rb b/config/environments/staging.rb index 7541e78ae1..695f61a0a1 100644 --- a/config/environments/staging.rb +++ b/config/environments/staging.rb @@ -11,7 +11,7 @@ Openfoodnetwork::Application.configure do config.action_controller.perform_caching = true # Disable Rails's static asset server (Apache or nginx will already do this) - config.serve_static_assets = false + config.serve_static_files = false # Compress JavaScripts and CSS config.assets.compress = true diff --git a/config/environments/test.rb b/config/environments/test.rb index f84b7f5f7f..c607e32bdc 100644 --- a/config/environments/test.rb +++ b/config/environments/test.rb @@ -10,7 +10,7 @@ Openfoodnetwork::Application.configure do config.eager_load = false # Configure static asset server for tests with Cache-Control for performance - config.serve_static_assets = true + config.serve_static_files = true config.static_cache_control = "public, max-age=3600" # Separate cache stores when running in parallel