Skip to content

wetfish/FishVision

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

8 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

# 🐟 FishVision  

Prometheus β†’ Alertmanager β†’ IRC alerting pipeline using [alertmanager-irc-relay](https://github.com/google/alertmanager-irc-relay).  

This project provides an **end-to-end monitoring and alerting stack** where Prometheus alerts are routed to IRC in real time.  

---

## πŸ“Œ Audience  
- DevOps  
- SRE  
- Infrastructure Engineers  
- Incident Response Teams  

---

## 🎯 Objective  
Deliver **critical Prometheus alerts** (e.g., high CPU, disk full) to a designated IRC channel to improve visibility and reduce mean time to response.  

---

## πŸ—‚οΈ Project Structure  

FishVision/ β”œβ”€β”€ alertmanager/ β”‚ └── alertmanager.yml # Alertmanager config with webhook receiver β”œβ”€β”€ alertmanager-irc-relay.yaml # IRC relay deployment config β”œβ”€β”€ docker-compose.yml # Compose stack for Prometheus, Alertmanager, Grafana, IRC β”œβ”€β”€ grafana/ # Grafana dashboards (extendable) β”œβ”€β”€ irc-deamon/ β”‚ β”œβ”€β”€ Dockerfile.irc # IRC server container β”‚ └── config.yml # IRC server configuration β”œβ”€β”€ prometheus/ β”‚ β”œβ”€β”€ alert.rules.yml # Prometheus alerting rules β”‚ └── prometheus.yml # Prometheus scrape + rule config └── utils/ └── node-exporter-installer.sh # Helper script to install Node Exporter


---

## 🧱 Architecture  

| Component           | Description |
|---------------------|-------------|
| **Node Exporter**   | Exposes host-level metrics from Linux systems |
| **Prometheus**      | Scrapes metrics and evaluates alert rules |
| **Alertmanager**    | Routes alerts and sends notifications |
| **IRC Relay Bot**   | Receives webhooks and relays alerts to IRC |
| **IRC Server**      | Hosts the target IRC channel (e.g., `#alerts`) |
| **Grafana**         | Visualizes Prometheus data and alerting context |

---

## πŸ”§ Prerequisites  
- Docker & Docker Compose installed  
- Outbound IRC traffic allowed from relay host  
- Working IRC server (local or external)  

Optional: Node Exporter installed on monitored hosts (script provided in `utils/`).  

---

## βš™οΈ Quick Start  

1. **Install Node Exporter (optional)**  
   ```bash
   ./utils/node-exporter-installer.sh
  1. Start the stack

    docker-compose up -d
  2. Access services

  3. Trigger a test alert

    stress-ng --cpu 4 --timeout 180s

    Expected message in #alerts:

    [FIRING] HighCPUUsage: server1.example.com has high CPU
    

πŸ› οΈ Maintenance

Task Frequency Notes
Test alert delivery Monthly Simulate CPU load & verify IRC
Update IRC relay container Quarterly docker pull ghcr.io/google/alertmanager-irc-relay
Rotate bot nick/channel As needed Update relay flags in config
Update alert rules As needed Edit prometheus/alert.rules.yml + restart Prometheus

πŸ”’ Security Notes

  • Run relay on a private network or behind a reverse proxy (NGINX, Caddy)
  • Enable logging for relay HTTP traffic
  • Restrict IRC server access as appropriate

About

FishVision - Monitoring and Observabiltiy stack with alerting to IRC

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages