docker-gitlab icon indicating copy to clipboard operation
docker-gitlab copied to clipboard

healthcheck not works

Open GordonHuangYong opened this issue 1 year ago • 3 comments

run

curl http://localhost/-/liveness

response

{"error":"Not Found","status":404}

run

curl http://127.0.0.1/-/liveness

response

{"status":"ok"}

GordonHuangYong avatar Aug 29 '24 03:08 GordonHuangYong

i modify the file /usr/local/sbin/healthcheck

#!/bin/bash
url=http://127.0.0.1/-/liveness
options=( '--insecure' '--location' '--silent' )
curl "${options[@]}" $url

GordonHuangYong avatar Aug 29 '24 03:08 GordonHuangYong

Hi @GordonHuangYong , thank you for reporting. As also reported in a part of #2766, current healthcheck script uses localhost and it is resolved to ::1 (IPv6 loopback address) that is not listed in monitoring IP whitelist by default.

The author of #2766 clearly described the root cause and fix then asked, "are you interested in a PR". The maintainer respond, "Feel free to provide an PR". So I thought that if I waited a while, a pull request would be submitted. However, none of the proposed fixes have been submitted as pull requests at this time.

Can you create a pull request to fix this issue? Or should I do it?

kkimurak avatar Aug 29 '24 04:08 kkimurak

Thanks for the invitation but No PR. not good at writing in english and coding

GordonHuangYong avatar Aug 29 '24 05:08 GordonHuangYong