Graylog2 / graylog-docker

Official Graylog Docker image
https://hub.docker.com/r/graylog/graylog/
Apache License 2.0
367 stars 133 forks source link

at least 3.0 health checks are buggy #100

Closed Loki-Afro closed 4 years ago

Loki-Afro commented 4 years ago

There was a recent change in health_check.sh with 5757b99cabd3e2d57231d11558d03530b9b3ff48

With a sematic which is not backward compatible but happened from 3.0.2-1 to 3.0.2-2 or 3.0.2-3.

http_publish_uri is not optional anymore and has to be set in the graylog configuration. The grayloog configuration states that this property is optional!

#### HTTP publish URI
#
# The HTTP URI of this Graylog node which is used to communicate with the other Graylog nodes in the cluster and by all
# clients using the Graylog web interface.
#
# The URI will be published in the cluster discovery APIs, so that other Graylog nodes will be able to find and connect to this Graylog node.
#
# This configuration setting has to be used if this Graylog node is available on another network interface than $http_bind_address,
# for example if the machine has multiple network interfaces or is behind a NAT gateway.
#
# If $http_bind_address contains a wildcard IPv4 address (0.0.0.0), the first non-loopback IPv4 address of this machine will be used.
# This configuration setting *must not* contain a wildcard address!
#
# Default: http://$http_bind_address/

This lets the health check fail with exit code 1 and the same log message and exit code (which is a bit useless when not looking into the check itself :/

So a few ideas/todos

What did I do to fix my setup: added http_publish_uri = 127.0.0.1:9000 to the configuration

jalogisch commented 4 years ago

I'm closing this issue, as it is duplicating #98. Please subscribe to that issue and add comments there for any remarks you have and to track the progress of the issue.

Fix is already proposed in https://github.com/Graylog2/graylog-docker/blob/9805213f96ed3213247ecf65f483710823f3f92c/health_check.sh#L52-L68

This will be backported to the 3.0 image

Thank you!