Use provided argument or fall-back for health-bind.
The following arguments may used to specifiy health-check behavior: * `-healthcheck` : Enable healthcheck (default: `false`) * `-healthbind=[::1]:8086` : Override Healthcheck bind-address (default: `[::]:8086` Or use Environmentvariables `HEALTHCHECK` and `HEALTHBIND`
This commit is contained in:
parent
c7c83926e1
commit
cf6cce277f
@ -207,13 +207,10 @@ func Run() {
|
||||
}
|
||||
|
||||
func health_endpoint() {
|
||||
var (
|
||||
health_bind = "0.0.0.0:8086"
|
||||
)
|
||||
health := healthchecking.NewHandler()
|
||||
health.AddLivenessCheck("goroutine-threshold", healthchecking.GoroutineCountCheck(100))
|
||||
log.Printf("Healthcheck listening on http://%s", health_bind)
|
||||
http.ListenAndServe(health_bind, health)
|
||||
log.Printf("Healthcheck listening on http://%s", *healtbind)
|
||||
http.ListenAndServe(*healtbind, health)
|
||||
}
|
||||
|
||||
func prom_export() {
|
||||
|
Loading…
Reference in New Issue
Block a user