Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRoger Meier <r.meier@siemens.com>2019-04-07 22:21:52 +0300
committerRoger Meier <r.meier@siemens.com>2019-04-30 19:10:57 +0300
commitaebb2f70257882dd530b820f3cfdd67621d2a3fd (patch)
treeffc70dec184fbd478ad0898368ec58ad5398ef16 /app/models/application_setting_implementation.rb
parent2432a540cff461c5d9c0346dd4021229078d674d (diff)
feat: allow Sentry configuration to be passed on gitlab.yml
Diffstat (limited to 'app/models/application_setting_implementation.rb')
-rw-r--r--app/models/application_setting_implementation.rb16
1 files changed, 16 insertions, 0 deletions
diff --git a/app/models/application_setting_implementation.rb b/app/models/application_setting_implementation.rb
index b413ffddb9d..557215ff4dc 100644
--- a/app/models/application_setting_implementation.rb
+++ b/app/models/application_setting_implementation.rb
@@ -183,6 +183,22 @@ module ApplicationSettingImplementation
clientside_sentry_dsn.strip! if clientside_sentry_dsn.present?
end
+ def sentry_enabled
+ Gitlab.config.sentry.enabled || read_attribute(:sentry_enabled)
+ end
+
+ def sentry_dsn
+ Gitlab.config.sentry.dsn || read_attribute(:sentry_dsn)
+ end
+
+ def clientside_sentry_enabled
+ Gitlab.config.sentry.enabled || read_attribute(:clientside_sentry_enabled)
+ end
+
+ def clientside_sentry_dsn
+ Gitlab.config.sentry.dsn || read_attribute(:clientside_sentry_dsn)
+ end
+
def performance_bar_allowed_group
Group.find_by_id(performance_bar_allowed_group_id)
end