about summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--Gemfile1
-rw-r--r--Gemfile.lock4
-rw-r--r--config/boot.rb11
3 files changed, 16 insertions, 0 deletions
diff --git a/Gemfile b/Gemfile
index 782c0da3c..abee826d4 100644
--- a/Gemfile
+++ b/Gemfile
@@ -19,6 +19,7 @@ gem 'paperclip', '~> 5.1'
 gem 'paperclip-av-transcoder', '~> 0.6'
 
 gem 'addressable', '~> 2.5'
+gem 'bootsnap'
 gem 'cld3', '~> 3.1'
 gem 'devise', '~> 4.2'
 gem 'devise-two-factor', '~> 3.0'
diff --git a/Gemfile.lock b/Gemfile.lock
index 936c1af6b..fd463edf5 100644
--- a/Gemfile.lock
+++ b/Gemfile.lock
@@ -67,6 +67,8 @@ GEM
       rack (>= 0.9.0)
     binding_of_caller (0.7.2)
       debug_inspector (>= 0.0.1)
+    bootsnap (0.2.14)
+      msgpack (~> 1.0)
     brakeman (3.6.1)
     builder (3.2.3)
     bullet (5.5.1)
@@ -235,6 +237,7 @@ GEM
     mimemagic (0.3.2)
     mini_portile2 (2.1.0)
     minitest (5.10.2)
+    msgpack (1.1.0)
     multi_json (1.12.1)
     net-scp (1.2.1)
       net-ssh (>= 2.6.5)
@@ -471,6 +474,7 @@ DEPENDENCIES
   aws-sdk (~> 2.9)
   better_errors (~> 2.1)
   binding_of_caller (~> 0.7)
+  bootsnap
   brakeman (~> 3.6)
   bullet (~> 5.5)
   bundler-audit (~> 0.5)
diff --git a/config/boot.rb b/config/boot.rb
index 30f5120df..703738b76 100644
--- a/config/boot.rb
+++ b/config/boot.rb
@@ -1,3 +1,14 @@
 ENV['BUNDLE_GEMFILE'] ||= File.expand_path('../Gemfile', __dir__)
 
 require 'bundler/setup' # Set up gems listed in the Gemfile.
+require 'bootsnap'
+
+Bootsnap.setup(
+  cache_dir:            'tmp/cache',
+  development_mode:     ENV['RAILS_ENV'] == 'development',
+  load_path_cache:      true,
+  autoload_paths_cache: true,
+  disable_trace:        true,
+  compile_cache_iseq:   false,
+  compile_cache_yaml:   false
+)