commit 9301a4c24f71a507469c364434fc52b3c910081a
parent 858668999f3102ae27e58faefb0a5c7b36ebb2af
Author: Christian Grothoff <christian@grothoff.org>
Date: Tue, 3 Jun 2025 01:03:27 +0200
bind alertmanager to loopback-only
Diffstat:
2 files changed, 14 insertions(+), 0 deletions(-)
diff --git a/roles/monitoring/files/etc/default/prometheus-alertmanager b/roles/monitoring/files/etc/default/prometheus-alertmanager
@@ -0,0 +1,5 @@
+# Set the command-line arguments to pass to the server.
+# Due to shell escaping, to pass backslashes for regexes, you need to double
+# them (\\d for \d). If running under systemd, you need to double them again
+# (\\\\d to mean \d), and escape newlines too.
+ARGS="--web.listen-address=127.0.0.1:9093 --cluster.listen-address=127.0.0.1:9094"
diff --git a/roles/monitoring/tasks/main.yml b/roles/monitoring/tasks/main.yml
@@ -134,6 +134,15 @@
mode: "0644"
notify: Restart node-exporter
+- name: Configure node-exporter
+ copy:
+ src: etc/default/prometheus-alertmanager
+ dest: /etc/default/prometheus-alertmanager
+ owner: root
+ group: root
+ mode: "0644"
+ notify: Restart node-exporter
+
- name: Configure postgres-exporter
copy:
src: etc/default/prometheus-postgres-exporter