packages/utils/prometheus-node-exporter-ucode/files/extra/dnsmasq.uc
Andre Heider 06c2ef2ce4 prometheus-node-exporter-ucode: add new package
This is a port of prometheus-node-exporter-lua to ucode.

Signed-off-by: Andre Heider <a.heider@gmail.com>
2023-08-25 10:18:26 +02:00

6 lines
126 B
Ucode

const x = ubus.call("dnsmasq", "metrics");
if (!x)
return false;
for (let i in x)
gauge(`dnsmasq_${i}_total`)(null, x[i]);