diff options
author | Patricio Cano <suprnova32@gmail.com> | 2016-07-14 21:19:40 +0300 |
---|---|---|
committer | Patricio Cano <suprnova32@gmail.com> | 2016-07-19 01:52:29 +0300 |
commit | defb8660c08a904a385b584280f72fc6a5a94c6e (patch) | |
tree | 1a93c424e4ad3ffb3d18350fdaaaa6c43879bad1 /app/controllers/admin | |
parent | 777a080892f710915c8f4d62864813ef388a1873 (diff) |
Added the ability to block sign ups using a domain blacklist.
Diffstat (limited to 'app/controllers/admin')
-rw-r--r-- | app/controllers/admin/application_settings_controller.rb | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/app/controllers/admin/application_settings_controller.rb b/app/controllers/admin/application_settings_controller.rb index 23ba83aba0e..3e27320ee5c 100644 --- a/app/controllers/admin/application_settings_controller.rb +++ b/app/controllers/admin/application_settings_controller.rb @@ -64,6 +64,7 @@ class Admin::ApplicationSettingsController < Admin::ApplicationController params[:application_setting][:disabled_oauth_sign_in_sources] = AuthHelper.button_based_providers.map(&:to_s) - Array(enabled_oauth_sign_in_sources) + params.delete(:domain_blacklist_raw) if params[:domain_blacklist_file] params.require(:application_setting).permit( :default_projects_limit, @@ -112,6 +113,9 @@ class Admin::ApplicationSettingsController < Admin::ApplicationController :container_registry_token_expire_delay, :repository_storage, :enabled_git_access_protocol, + :domain_blacklist_enabled, + :domain_blacklist_raw, + :domain_blacklist_file, restricted_visibility_levels: [], import_sources: [], disabled_oauth_sign_in_sources: [] |