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:
authorStan Hu <stanhu@gmail.com>2018-07-27 22:19:51 +0300
committerStan Hu <stanhu@gmail.com>2018-07-29 00:35:02 +0300
commit22d44ae9a699c418aba442cd99eec8f58d5fa006 (patch)
tree035cd854d43f390b3684e123be74482485e25296 /lib/gitlab/middleware
parenteb2bc7d99a99981150f32ac2469bff29eebbfa19 (diff)
Use /-/health instead of breaking /-/liveness
Diffstat (limited to 'lib/gitlab/middleware')
-rw-r--r--lib/gitlab/middleware/basic_health_check.rb (renamed from lib/gitlab/middleware/liveness_health_check.rb)8
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/gitlab/middleware/liveness_health_check.rb b/lib/gitlab/middleware/basic_health_check.rb
index 404c506a08e..f2a03217098 100644
--- a/lib/gitlab/middleware/liveness_health_check.rb
+++ b/lib/gitlab/middleware/basic_health_check.rb
@@ -9,20 +9,20 @@
module Gitlab
module Middleware
- class LivenessHealthCheck
+ class BasicHealthCheck
# This can't be frozen because Rails::Rack::Logger wraps the body
# rubocop:disable Style/MutableConstant
- OK_RESPONSE = [200, { 'Content-Type' => 'text/plain' }, ["GitLab is alive"]]
+ OK_RESPONSE = [200, { 'Content-Type' => 'text/plain' }, ["GitLab OK"]]
EMPTY_RESPONSE = [404, { 'Content-Type' => 'text/plain' }, [""]]
# rubocop:enable Style/MutableConstant
- LIVENESS_PATH = '/-/liveness'
+ HEALTH_PATH = '/-/health'
def initialize(app)
@app = app
end
def call(env)
- return @app.call(env) unless env['PATH_INFO'] == LIVENESS_PATH
+ return @app.call(env) unless env['PATH_INFO'] == HEALTH_PATH
request = Rack::Request.new(env)