summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNick Thomas <nick@gitlab.com>2017-12-14 15:14:57 +0000
committerNick Thomas <nick@gitlab.com>2017-12-14 15:14:57 +0000
commit9b00203904d9e8a98018ec6bd193054ffffb60c6 (patch)
treefcb97676d2a4b255f36cfa3a22f5228cb0aa7b29
parent391bb437611b91e2767384ff9852beb573c84996 (diff)
downloadgitlab-ce-9b00203904d9e8a98018ec6bd193054ffffb60c6.tar.gz
Add eager-load paths to autoload paths to fix Rake tasks
Rake doesn't respect eager-loading, so to avoid explicit requires we have to duplicate the eager-load config into the auto-load config. This backports an EE change made in https://gitlab.com/gitlab-org/gitlab-ee/merge_requests/3706
-rw-r--r--config/application.rb4
1 files changed, 4 insertions, 0 deletions
diff --git a/config/application.rb b/config/application.rb
index 6436f887d14..25c5a8f5a99 100644
--- a/config/application.rb
+++ b/config/application.rb
@@ -34,6 +34,10 @@ module Gitlab
config.generators.templates.push("#{config.root}/generator_templates")
+ # Rake tasks ignore the eager loading settings, so we need to set the
+ # autoload paths explicitly
+ config.autoload_paths = config.eager_load_paths.dup
+
# Only load the plugins named here, in the order given (default is alphabetical).
# :all can be used as a placeholder for all plugins not explicitly named.
# config.plugins = [ :exception_notification, :ssl_requirement, :all ]