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
path: root/lib/tasks
diff options
context:
space:
mode:
authorStan Hu <stanhu@gmail.com>2015-09-06 10:29:41 +0300
committerStan Hu <stanhu@gmail.com>2015-09-06 10:35:16 +0300
commit30039dae6326e7b1ae7e3e2d321def122cda3e36 (patch)
tree17ce30fd7774098a90a9848fe4835795d8c727cf /lib/tasks
parent50f76ae0eae29f7362702da274055f76a350ee6f (diff)
Upgrade Redis requirement check to 2.4.0 per https://github.com/mperham/sidekiq/pull/957
Closes #2222 Closes #2445
Diffstat (limited to 'lib/tasks')
-rw-r--r--lib/tasks/gitlab/check.rake11
1 files changed, 7 insertions, 4 deletions
diff --git a/lib/tasks/gitlab/check.rake b/lib/tasks/gitlab/check.rake
index 2b9688c1b40..7999fe0b0e1 100644
--- a/lib/tasks/gitlab/check.rake
+++ b/lib/tasks/gitlab/check.rake
@@ -278,7 +278,7 @@ namespace :gitlab do
fix_and_rerun
end
end
-
+
def check_uploads
print "Uploads directory setup correctly? ... "
@@ -331,15 +331,18 @@ namespace :gitlab do
end
def check_redis_version
- print "Redis version >= 2.0.0? ... "
+ min_redis_version = "2.4.0"
+ print "Redis version >= #{min_redis_version}? ... "
redis_version = run(%W(redis-cli --version))
- if redis_version.try(:match, /redis-cli 2.\d.\d/) || redis_version.try(:match, /redis-cli 3.\d.\d/)
+ redis_version = redis_version.try(:match, /redis-cli (.*)/)
+ if redis_version &&
+ (Gem::Version.new(redis_version[1]) > Gem::Version.new(min_redis_version))
puts "yes".green
else
puts "no".red
try_fixing_it(
- "Update your redis server to a version >= 2.0.0"
+ "Update your redis server to a version >= #{min_redis_version}"
)
for_more_information(
"gitlab-public-wiki/wiki/Trouble-Shooting-Guide in section sidekiq"