From 4bd9e36ff45b2001b048a23a218e26605deac7d0 Mon Sep 17 00:00:00 2001 From: Georg Date: Fri, 6 Aug 2021 17:42:45 +0200 Subject: Mass Commit 06/08/2021 Signed-off-by: Georg --- .../alertmanager-irc-libertacasa.service | 14 ++++++++++ .../alertmanager-irc-libertacasa.yaml | 32 ++++++++++++++++++++++ .../alertmanager-irc-tripsit.service | 15 ++++++++++ .../alertmanager-irc-tripsit.yaml | 30 ++++++++++++++++++++ 4 files changed, 91 insertions(+) create mode 100644 Prometheus_Alertmanager_IRC_Relay/alertmanager-irc-libertacasa.service create mode 100644 Prometheus_Alertmanager_IRC_Relay/alertmanager-irc-libertacasa.yaml create mode 100644 Prometheus_Alertmanager_IRC_Relay/alertmanager-irc-tripsit.service create mode 100644 Prometheus_Alertmanager_IRC_Relay/alertmanager-irc-tripsit.yaml (limited to 'Prometheus_Alertmanager_IRC_Relay') diff --git a/Prometheus_Alertmanager_IRC_Relay/alertmanager-irc-libertacasa.service b/Prometheus_Alertmanager_IRC_Relay/alertmanager-irc-libertacasa.service new file mode 100644 index 0000000..70b8285 --- /dev/null +++ b/Prometheus_Alertmanager_IRC_Relay/alertmanager-irc-libertacasa.service @@ -0,0 +1,14 @@ +[Unit] +After=network.target +Description=Alertmanager IRC Relay for LibertaCasa + +[Service] +Type=simple +User=alertmanager-irc +Group=alertmanager-irc +WorkingDirectory=/opt/alertmanager-irc +Restart=always +ExecStart=/opt/alertmanager-irc/alertmanager-irc-relay --config /etc/prometheus/alertmanager-irc-libertacasa.yaml + +[Install] +WantedBy=multi-user.target diff --git a/Prometheus_Alertmanager_IRC_Relay/alertmanager-irc-libertacasa.yaml b/Prometheus_Alertmanager_IRC_Relay/alertmanager-irc-libertacasa.yaml new file mode 100644 index 0000000..23fa763 --- /dev/null +++ b/Prometheus_Alertmanager_IRC_Relay/alertmanager-irc-libertacasa.yaml @@ -0,0 +1,32 @@ +http_host: 127.0.0.1 +http_port: 2410 + +irc_host: irc.liberta.casa +irc_port: 6697 +irc_host_password: watchdog:$PASS + +irc_nickname: watchdog +# Password used to identify with NickServ +#irc_nickname_password: $NSPASS +# Use this IRC real name +irc_realname: Alertmanager on mercury.lysergic.dev + +irc_channels: + - name: "#universe" + password: $JTOKEN +# - name: "#admins" + +msg_once_per_alert_group: no +use_privmsg: yes +msg_template: "Severity: {{ .Labels.severity }} - Job: {{ .Labels.job }} - Title: {{ .Annotations.title}} - Body: {{ .Annotations.description }} - Summary: {{ .Labels.alertname }} on {{ .Labels.instance }} is {{ .Status }}" +# Note: When sending only one message per alert group the default +# msg_template is set to +# "Alert {{ .GroupLabels.alertname }} for {{ .GroupLabels.job }} is {{ .Status }}" + +# Set the internal buffer size for alerts received but not yet sent to IRC. +alert_buffer_size: 2048 + +nickserv_identify_patterns: + - "identify via /msg NickServ identify " + - "type /msg NickServ IDENTIFY password" + - "authenticate yourself to services with the IDENTIFY command" diff --git a/Prometheus_Alertmanager_IRC_Relay/alertmanager-irc-tripsit.service b/Prometheus_Alertmanager_IRC_Relay/alertmanager-irc-tripsit.service new file mode 100644 index 0000000..72303ea --- /dev/null +++ b/Prometheus_Alertmanager_IRC_Relay/alertmanager-irc-tripsit.service @@ -0,0 +1,15 @@ +[Unit] +After=network.target +Description=Alertmanager IRC Relay for TripSit + +[Service] +Type=simple +User=alertmanager-irc +Group=alertmanager-irc +WorkingDirectory=/opt/alertmanager-irc +Restart=always +ExecStart=/opt/alertmanager-irc/alertmanager-irc-relay --config /etc/prometheus/alertmanager-irc-tripsit.yaml + +[Install] +WantedBy=multi-user.target + diff --git a/Prometheus_Alertmanager_IRC_Relay/alertmanager-irc-tripsit.yaml b/Prometheus_Alertmanager_IRC_Relay/alertmanager-irc-tripsit.yaml new file mode 100644 index 0000000..71df239 --- /dev/null +++ b/Prometheus_Alertmanager_IRC_Relay/alertmanager-irc-tripsit.yaml @@ -0,0 +1,30 @@ +http_host: 127.0.0.1 +http_port: 2420 + +irc_host: newirc.tripsit.me +irc_port: 6697 + +irc_nickname: watchdog +# Password used to identify with NickServ +irc_nickname_password: $NSPASS +# Use this IRC real name +irc_realname: Infrastructure Monitoring + +irc_channels: + - name: "#_systems" + - name: "#tripsit-dev" + +msg_once_per_alert_group: no +use_privmsg: yes +msg_template: "ALERT: {{ .Labels.alertname }} on {{ .Labels.instance }} is {{ .Status }}" +# Note: When sending only one message per alert group the default +# msg_template is set to +# "Alert {{ .GroupLabels.alertname }} for {{ .GroupLabels.job }} is {{ .Status }}" + +# Set the internal buffer size for alerts received but not yet sent to IRC. +alert_buffer_size: 2048 + +nickserv_identify_patterns: + - "identify via /msg NickServ identify " + - "type /msg NickServ IDENTIFY password" + - "authenticate yourself to services with the IDENTIFY command" -- cgit v1.2.3