diff options
author | Zeger-Jan van de Weg <git@zjvandeweg.nl> | 2018-04-12 09:12:21 +0200 |
---|---|---|
committer | Zeger-Jan van de Weg <git@zjvandeweg.nl> | 2018-04-12 15:23:36 +0200 |
commit | a752c56ca82d6f0fdee340f5d494347a4aa90072 (patch) | |
tree | 721698bb52f983d58031cd510732546a323d4e71 /lib/gitlab.rb | |
parent | b2f57a561f0540f8e33c2d580252e6f95e9cf182 (diff) | |
download | gitlab-ce-a752c56ca82d6f0fdee340f5d494347a4aa90072.tar.gz |
Deprecate legacy disk paths
Direct disk access is impossible on environments where components run in
their own container. There for constructing the path should not be done
except for exceptional cases.
One of the considerations, instead of logging, was to use Sentry. For
now I've chosen not to use this as the impact of this change is hard to
determine. Getting this in now will allow us to checkout the impact on
dev.gitlab.org and staging.
Diffstat (limited to 'lib/gitlab.rb')
-rw-r--r-- | lib/gitlab.rb | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/lib/gitlab.rb b/lib/gitlab.rb index aa9fd36d9ff..37ce01925bb 100644 --- a/lib/gitlab.rb +++ b/lib/gitlab.rb @@ -12,4 +12,12 @@ module Gitlab def self.staging? Gitlab.config.gitlab.url == 'https://staging.gitlab.com' end + + def self.dev? + Gitlab.config.gitlab.url == 'https://dev.gitlab.org' + end + + def self.inc_controlled? + dev? || staging? || com? + end end |