From c5866336131b5f6b042541cd677743c455b6c0b9 Mon Sep 17 00:00:00 2001 From: Alex Auvolat Date: Mon, 8 Mar 2021 22:55:55 +0100 Subject: Add node-exporter for metrics collection --- app/metrics/deploy/metrics.hcl | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100644 app/metrics/deploy/metrics.hcl (limited to 'app') diff --git a/app/metrics/deploy/metrics.hcl b/app/metrics/deploy/metrics.hcl new file mode 100644 index 0000000..df82b5e --- /dev/null +++ b/app/metrics/deploy/metrics.hcl @@ -0,0 +1,25 @@ +job "metrics" { + datacenters = ["dc1"] + type = "system" + priority = "100" + + group "node_exporter" { + task "node_exporter" { + driver = "docker" + + config { + image = "quay.io/prometheus/node-exporter:latest" + network_mode = "host" + volumes = [ + "/:/host:ro,rslave" + ] + args = [ "--path.rootfs=/host" ] + } + + resources { + cpu = 50 + memory = 40 + } + } + } +} -- cgit v1.2.3