diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2020-05-20 17:34:42 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2020-05-20 17:34:42 +0300 |
commit | 9f46488805e86b1bc341ea1620b866016c2ce5ed (patch) | |
tree | f9748c7e287041e37d6da49e0a29c9511dc34768 /lib/gitlab/config_checker | |
parent | dfc92d081ea0332d69c8aca2f0e745cb48ae5e6d (diff) |
Add latest changes from gitlab-org/gitlab@13-0-stable-ee
Diffstat (limited to 'lib/gitlab/config_checker')
-rw-r--r-- | lib/gitlab/config_checker/external_database_checker.rb | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/lib/gitlab/config_checker/external_database_checker.rb b/lib/gitlab/config_checker/external_database_checker.rb new file mode 100644 index 00000000000..795082a10a0 --- /dev/null +++ b/lib/gitlab/config_checker/external_database_checker.rb @@ -0,0 +1,27 @@ +# frozen_string_literal: true + +module Gitlab + module ConfigChecker + module ExternalDatabaseChecker + extend self + + # DB is considered deprecated if it is below version 11 + def db_version_deprecated? + Gitlab::Database.version.to_f < 11 + end + + def check + return [] unless db_version_deprecated? + + [ + { + type: 'warning', + message: _('Note that PostgreSQL 11 will become the minimum required PostgreSQL version in GitLab 13.0 (May 2020). '\ + 'PostgreSQL 9.6 and PostgreSQL 10 will no longer be supported in GitLab 13.0. '\ + 'Please consider upgrading your PostgreSQL version (%{db_version}) soon.') % { db_version: Gitlab::Database.version.to_s } + } + ] + end + end + end +end |