All Projects → google → alertmanager-irc-relay

google / alertmanager-irc-relay

Licence: Apache-2.0 License
Send Prometheus Alerts to IRC using Webhooks

Programming Languages

go
31211 projects - #10 most used programming language
Dockerfile
14818 projects

Projects that are alternatives of or similar to alertmanager-irc-relay

Karma
Alert dashboard for Prometheus Alertmanager
Stars: ✭ 1,007 (+2188.64%)
Mutual labels:  alerting, prometheus
Grafana
The open and composable observability and data visualization platform. Visualize metrics, logs, and traces from multiple sources like Prometheus, Loki, Elasticsearch, InfluxDB, Postgres and many more.
Stars: ✭ 45,930 (+104286.36%)
Mutual labels:  alerting, prometheus
Ansible Alertmanager
Deploy Prometheus Alertmanager service
Stars: ✭ 93 (+111.36%)
Mutual labels:  alerting, prometheus
Ciao
HTTP checks & tests (private & public) monitoring - check the status of your URL
Stars: ✭ 1,322 (+2904.55%)
Mutual labels:  alerting, prometheus
Alertmanager2es
Receives HTTP webhook notifications from AlertManager and inserts them into an Elasticsearch index for searching and analysis
Stars: ✭ 173 (+293.18%)
Mutual labels:  alerting, prometheus
Unsee
Alert dashboard for Prometheus Alertmanager
Stars: ✭ 700 (+1490.91%)
Mutual labels:  alerting, prometheus
Prometheus
The Prometheus monitoring system and time series database.
Stars: ✭ 40,114 (+91068.18%)
Mutual labels:  alerting, prometheus
Hastic Server
Hastic data management server for analyzing patterns and anomalies from Grafana
Stars: ✭ 292 (+563.64%)
Mutual labels:  alerting, prometheus
Pat
Prometheus Alert Testing utility
Stars: ✭ 156 (+254.55%)
Mutual labels:  alerting, prometheus
Hollowtrees
A ruleset based watchguard to keep spot/preemptible instance based clusters safe, with plugins for VMs, Kubernetes, Prometheus and Pipeline
Stars: ✭ 141 (+220.45%)
Mutual labels:  alerting, prometheus
Prom2teams
prom2teams is an HTTP server built with Python that receives alert notifications from a previously configured Prometheus Alertmanager instance and forwards it to Microsoft Teams using defined connectors
Stars: ✭ 122 (+177.27%)
Mutual labels:  alerting, prometheus
Example Prometheus Nodejs
Prometheus monitoring example with Node.js
Stars: ✭ 249 (+465.91%)
Mutual labels:  alerting, prometheus
Awesome Prometheus Alerts
🚨 Collection of Prometheus alerting rules
Stars: ✭ 3,323 (+7452.27%)
Mutual labels:  alerting, prometheus
Netdata
Real-time performance monitoring, done right! https://www.netdata.cloud
Stars: ✭ 57,056 (+129572.73%)
Mutual labels:  alerting, prometheus
zfs exporter
Prometheus ZFS exporter
Stars: ✭ 52 (+18.18%)
Mutual labels:  prometheus
godot-twicil
Godot TwiCIL – Godot Twitch Chat Interaction Layer
Stars: ✭ 57 (+29.55%)
Mutual labels:  irc
github exporter
Prometheus exporter for GitHub
Stars: ✭ 21 (-52.27%)
Mutual labels:  prometheus
yabeda-prometheus
Adapter to expose metrics collected by Yabeda plugins to Prometheus
Stars: ✭ 77 (+75%)
Mutual labels:  prometheus
deluge exporter
Prometheus exporter for the Deluge BitTorrent client
Stars: ✭ 24 (-45.45%)
Mutual labels:  prometheus
website
Prometheus monitoring mixins
Stars: ✭ 91 (+106.82%)
Mutual labels:  prometheus

Alertmanager IRC Relay

Alertmanager IRC Relay is a bot relaying Prometheus alerts to IRC. Alerts are received from Prometheus using Webhooks and are relayed to an IRC channel.

Configuring and running the bot

To configure and run the bot you need to create a YAML configuration file and pass it to the service. Running the service without a configuration will use the default test values and connect to a default IRC channel, which you probably do not want to do.

Example configuration:

# Start the HTTP server receiving alerts from Prometheus Webhook binding to
# this host/port.
#
http_host: localhost
http_port: 8000

# Connect to this IRC host/port.
#
# Note: SSL is enabled by default, use "irc_use_ssl: no" to disable.
irc_host: irc.example.com
irc_port: 7000
# Optionally set the server password
irc_host_password: myserver_password

# Use this IRC nickname.
irc_nickname: myalertbot
# Password used to identify with NickServ
irc_nickname_password: mynickserv_key
# Use this IRC real name
irc_realname: myrealname

# Optionally pre-join certain channels.
#
# Note: If an alert is sent to a non # pre-joined channel the bot will join
# that channel anyway before sending the message. Of course this cannot work
# with password-protected channels.
irc_channels:
  - name: "#mychannel"
  - name: "#myprivatechannel"
    password: myprivatechannel_key

# Define how IRC messages should be sent.
#
# Send only one message when webhook data is received.
# Note: By default a message is sent for each alert in the webhook data.
msg_once_per_alert_group: no
#
# Use PRIVMSG instead of NOTICE (default) to send messages.
# Note: Sending PRIVMSG from bots is bad practice, do not enable this unless
# necessary (e.g. unless NOTICEs would weaken your channel moderation policies)
use_privmsg: yes

# Define how IRC messages should be formatted.
#
# The formatting is based on golang's text/template .
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

# Patterns used to guess whether NickServ is asking us to IDENTIFY
# Note: If you need to change this because the bot is not catching a request
# from a rather common NickServ, please consider sending a PR to update the
# default config instead.
nickserv_identify_patterns:
  - "identify via /msg NickServ identify <password>"
  - "type /msg NickServ IDENTIFY password"
  - "authenticate yourself to services with the IDENTIFY command"

Running the bot (assuming $GOPATH and $PATH are properly setup for go):

$ go install github.com/google/alertmanager-irc-relay
$ alertmanager-irc-relay --config /path/to/your/config/file

The configuration file can reference environment variables. It is then possible to specify certain parameters directly when running the bot:

$ cat /path/to/your/config/file
...
http_port: $MY_SERVICE_PORT
...
irc_nickname_password: $NICKSERV_PASSWORD
...
$ export MY_SERVICE_PORT=8000 NICKSERV_PASSWORD=mynickserv_key
$ alertmanager-irc-relay --config /path/to/your/config/file

Prometheus configuration

Prometheus can be configured following the official Webhooks documentation. The url must specify the IRC channel name that alerts should be sent to:

send_resolved: false
url: http://localhost:8000/mychannel
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].