51 lines
1.3 KiB
Plaintext
51 lines
1.3 KiB
Plaintext
# NetBird Observability — Basis-Konfiguration (alle Linux-Nodes)
|
|
# Variablen aus /etc/default/telegraf: NODE_NAME, PROM_URL, LOKI_URL
|
|
|
|
[global_tags]
|
|
node = "${NODE_NAME}"
|
|
|
|
[agent]
|
|
interval = "15s"
|
|
flush_interval = "15s"
|
|
metric_batch_size = 1000
|
|
metric_buffer_limit = 20000
|
|
hostname = "${NODE_NAME}"
|
|
omit_hostname = false
|
|
|
|
# ---- Metriken → Prometheus Remote Write (imac) ----
|
|
[[outputs.http]]
|
|
url = "${PROM_URL}"
|
|
data_format = "prometheusremotewrite"
|
|
timeout = "10s"
|
|
namedrop = ["docker_log", "apache_log", "journal"]
|
|
[outputs.http.headers]
|
|
Content-Type = "application/x-protobuf"
|
|
Content-Encoding = "snappy"
|
|
X-Prometheus-Remote-Write-Version = "0.1.0"
|
|
Authorization = "Bearer ${TELEGRAF_TOKEN}"
|
|
|
|
# ---- Logs → Loki (imac) ----
|
|
[[outputs.loki]]
|
|
domain = "${LOKI_URL}"
|
|
endpoint = "/loki/api/v1/push"
|
|
timeout = "10s"
|
|
namepass = ["docker_log", "apache_log", "journal"]
|
|
sanitize_label_names = true
|
|
metric_name_label = ""
|
|
http_headers = { "Authorization" = "Bearer ${TELEGRAF_TOKEN}" }
|
|
|
|
# ---- Host-Metriken ----
|
|
[[inputs.cpu]]
|
|
percpu = false
|
|
totalcpu = true
|
|
[[inputs.mem]]
|
|
[[inputs.swap]]
|
|
[[inputs.system]]
|
|
fieldexclude = ["uptime_format"]
|
|
[[inputs.disk]]
|
|
ignore_fs = ["tmpfs", "devtmpfs", "overlay", "squashfs", "fuse.lxcfs"]
|
|
[[inputs.diskio]]
|
|
[[inputs.net]]
|
|
[[inputs.processes]]
|
|
[[inputs.kernel]]
|