Skip to content
Snippets Groups Projects
Commit 3240a6a3 authored by Sergey Yakubov's avatar Sergey Yakubov
Browse files

Merge pull request #77 in ASAPO/asapo from telegraf_health_check to develop

* commit '2a03a415':
  Improve telegraf health check
parents 382b47ed 2a03a415
No related branches found
No related tags found
No related merge requests found
......@@ -159,6 +159,8 @@ job "monitoring" {
network {
port "telegraf_stream" {
}
port "telegraf_health" {
}
}
}
......@@ -167,9 +169,9 @@ job "monitoring" {
port = "telegraf_stream"
check {
name = "telegraf-alive"
type = "script"
command = "/bin/pidof"
args = ["telegraf"]
type = "http"
path = "/"
port = "telegraf_health"
interval = "10s"
timeout = "2s"
}
......
......@@ -9,6 +9,9 @@
[[inputs.consul]]
[[inputs.internal]]
collect_memstats = false
[[outputs.file]]
files=["stdout"]
......@@ -16,3 +19,16 @@
[[outputs.influxdb]]
urls = ["http://localhost:{{ env "NOMAD_META_nginx_port" }}/influxdb"]
[[outputs.health]]
service_address = "http://{{ env "NOMAD_ADDR_telegraf_health" }}"
namepass = ["internal_write"]
tagpass = { output = ["influxdb"] }
[[outputs.health.compares]]
field = "buffer_size"
lt = 5000.0
[[outputs.health.contains]]
field = "buffer_size"
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment