From 7589551d68b2d7054d695bdb27bd950093b67f77 Mon Sep 17 00:00:00 2001 From: Sam Saffron Date: Wed, 10 Jun 2020 12:20:17 +1000 Subject: [PATCH] PERF: enable bootsnap globally If people wish to opt out they can use `DISABLE_BOOTSNAP = 1` Bootsnap is production ready and was tested on our production servers for safety. Promoting it now so it is enabled globally. Will result in faster application boot --- config/boot.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/config/boot.rb b/config/boot.rb index affd36c9bb4..572d833edd7 100644 --- a/config/boot.rb +++ b/config/boot.rb @@ -12,7 +12,7 @@ ENV['BUNDLE_GEMFILE'] ||= File.expand_path('../../Gemfile', __FILE__) require 'bundler/setup' if File.exists?(ENV['BUNDLE_GEMFILE']) -if (ENV['FORCE_BOOTSNAP'] == '1') || (ENV['RAILS_ENV'] != 'production' && ENV['RAILS_ENV'] != 'profile') +if (ENV['DISABLE_BOOTSNAP'] != '1') begin require 'bootsnap' rescue LoadError