diff options
-rw-r--r-- | config/initializers/7_omniauth.rb | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/config/initializers/7_omniauth.rb b/config/initializers/7_omniauth.rb index 6f1f267bf97..f29216a2cf1 100644 --- a/config/initializers/7_omniauth.rb +++ b/config/initializers/7_omniauth.rb @@ -17,3 +17,10 @@ OmniAuth.config.allowed_request_methods << :get if Gitlab.config.omniauth.auto_s OmniAuth.config.before_request_phase do |env| OmniAuth::RequestForgeryProtection.new(env).call end + +if Gitlab.config.omniauth.enabled + Gitlab.config.omniauth.providers.each do |provider| + next unless provider['name'] == 'kerberos' + require 'omniauth-kerberos' + end +end |