Commit 7c1854ab authored by Valery Sizov's avatar Valery Sizov

gitlab:check rake task checks ES version according to requirements

parent 9273de85
Please view this file on the master branch, on stable branches it's out of date.
## 8.14.0 (2016-11-22)
- gitlab:check rake task checks ES version according to requirements
## 8.13.1 (2016-10-25)
......
......@@ -986,11 +986,12 @@ namespace :gitlab do
client = Elasticsearch::Client.new(host: ApplicationSetting.current.elasticsearch_host,
port: ApplicationSetting.current.elasticsearch_port)
print "Elasticsearch version >= 2.0? ... "
print "Elasticsearch version >= 2.4? ... "
version = client.info["version"]["number"]
if version.starts_with?("2")
# The version is greater or equal to 2.4.0
if version.delete('.').to_i >= 240
puts "yes (#{version})".color(:green)
else
puts "no".color(:red)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment