Skip to content

violacase/Notify

Repository files navigation

πŸ“’ Notify Project - Linux Mint Notificaties

Complete gids en implementatie voor notificatiebeheer op Linux Mint

πŸ“‹ Projectoverzicht

Dit project bevat een uitgebreide gids voor het beheren van notificaties op Linux Mint, inclusief een volledig geΓ―mplementeerde lokale ntfy notificatieserver.

🎯 Doelstellingen

  1. Educatie - Leren hoe notificaties werken op Linux Mint
  2. Controle - Ongewenste notificaties (Bluetooth, Wi-Fi, etc.) uitschakelen
  3. Self-hosting - Eigen notificatieserver opzetten zonder cloud afhankelijkheden
  4. Automatisering - Scripts en monitoring integreren met notificaties

πŸ“š Documentatie

Het project bestaat uit drie hoofddocumenten:

Type: Interactieve HTML gids Status: βœ… Compleet

Uitgebreide handleiding over notificaties in Linux Mint Cinnamon:

  • Bluetooth notificaties uitschakelen (Blueman ConnectionNotifier)
  • Algemene notificatie-instellingen configureren
  • Web push notificaties in Firefox/Chrome/PWA
  • ntfy server self-hosting (VPS of lokaal)
  • UnifiedPush standaard en privacy-vriendelijke alternatieven
  • Praktische use cases voor sysadmins en developers

Features:

  • πŸŒ™ Dark/light mode toggle
  • πŸ“± Responsive design
  • 🧭 Sticky navigation met scroll tracking
  • ⬆️ Back-to-top button
  • πŸ”– Uitgebreide table of contents

Openen:

xdg-open "Linux Mint Notificaties Gids.html"

Type: Implementatieplan (Markdown) Status: βœ… Uitgevoerd

Gedetailleerd stappenplan voor het opzetten van een lokale ntfy server:

  • Systeemvereisten en huidige status analyse
  • Pre-compiled binary installatie
  • Configuratie met YAML
  • systemd user service setup
  • Desktop client (Ntfyr) installatie
  • Shell script voorbeelden
  • Troubleshooting gids

Lezen:

cat NTFY_LOCAL_SETUP_PLAN.md
# Of: xdg-open NTFY_LOCAL_SETUP_PLAN.md

Type: Gebruikershandleiding (Markdown) Status: βœ… Actief

Complete referentie voor je geΓ―nstalleerde ntfy server:

  • Quick start voorbeelden
  • Service beheer commando's
  • Script documentatie (4 helper scripts)
  • Praktische use cases (Git hooks, cron jobs, monitoring)
  • Troubleshooting gids
  • Emoji tags referentie

Lezen:

cat NTFY_SETUP_COMPLETE.md

Type: Implementatie en gebruikershandleiding (Markdown) Status: βœ… Actief

Complete gids voor de browser notificatie bridge:

  • Hoe het werkt - Technische architectuur en D-Bus integratie
  • Service beheer - Starten, stoppen, logs bekijken
  • Testing - Test met notify-send en echte browser notificaties
  • Configuratie - Topic routing aanpassen, filters toevoegen
  • Troubleshooting - Veelvoorkomende problemen oplossen
  • Use cases - WhatsApp Web, Gmail, Slack integratie

Lezen:

cat BROWSER_NOTIFICATION_BRIDGE.md

πŸš€ Wat is GeΓ―mplementeerd

ntfy Server (Lokaal)

  • Versie: ntfy 2.12.0
  • Poort: 8765 (localhost only)
  • URL: http://localhost:8765
  • Status: βœ… Draait via systemd user service
  • Auto-start: Ja (bij login)

🌐 Browser Notification Bridge (NIEUW!)

  • Status: βœ… GeΓ―mplementeerd en actief
  • Functie: Vangt browser notificaties (Chrome/Firefox/Zen: WhatsApp Web, Gmail, etc.) en stuurt ze door naar ntfy
  • Auto-start: Ja (systemd user service)
  • Documentatie: BROWSER_NOTIFICATION_BRIDGE.md

Wat het doet:

  • βœ… Vangt ALLE desktop notificaties (browsers + andere apps)
  • βœ… Stuurt door naar ntfy voor permanente opslag
  • βœ… Intelligente topic routing (WhatsApp β†’ whatsapp, Gmail β†’ gmail)
  • βœ… Werkt met WhatsApp Web, Gmail, Slack en alle web apps
  • βœ… Geen impact op normale desktop notificaties

Service beheer:

# Status checken
systemctl --user status chrome-notify-bridge.service

# Logs bekijken
journalctl --user -u chrome-notify-bridge.service -f

# Service herstarten
systemctl --user restart chrome-notify-bridge.service

Server beheer:

# Status checken
systemctl --user status ntfy.service

# Logs bekijken
journalctl --user -u ntfy.service -f

# Server herstarten
systemctl --user restart ntfy.service

# Health check
curl http://localhost:8765/v1/health

Ntfyr Desktop Client

  • Type: Flatpak applicatie
  • Status: βœ… GeΓ―nstalleerd
  • Functie: Desktop notificaties via Cinnamon

Starten:

flatpak run io.github.tobagin.Ntfyr

Configuratie:

  1. Open Ntfyr
  2. Add Server: http://localhost:8765
  3. Subscribe to topics: test, monitoring, system, backups

Helper Scripts

Locatie: ~/scripts/

Script Functie Gebruik
disk_monitor.sh Monitor schijfruimte ~/scripts/disk_monitor.sh
notify_on_complete.sh Wrapper voor langlopende taken ~/scripts/notify_on_complete.sh "command"
backup_notify.sh Backup notificaties ~/scripts/backup_notify.sh "name" "status"
nginx_reload_notify.sh Nginx reload met notificatie ~/scripts/nginx_reload_notify.sh

Alle scripts zijn executable (chmod +x) en direct te gebruiken.

🎯 Snel Starten

Notificatie Sturen

# Simpel
curl -d "Hello World!" http://localhost:8765/test

# Met titel en prioriteit
curl -H "Title: Belangrijk" \
     -H "Priority: high" \
     -d "Je bericht hier" \
     http://localhost:8765/alerts

# Met emoji tags
curl -H "Tags: rocket,sparkles" \
     -d "Deployment succesvol!" \
     http://localhost:8765/deployments

Script Voorbeelden

# Monitor disk space
~/scripts/disk_monitor.sh

# Wrap een langlopend commando
~/scripts/notify_on_complete.sh "npm run build"

# Custom topic
~/scripts/notify_on_complete.sh deployments "npm run deploy"

Integratie Voorbeelden

Git Hook (.git/hooks/post-commit):

#!/bin/bash
curl -H "Tags: git" \
     -d "Committed: $(git log -1 --pretty=%B)" \
     http://localhost:8765/git

Cron Job (crontab -e):

# Elk uur disk check
0 * * * * /home/kees/scripts/disk_monitor.sh

# Dagelijkse backup notificatie
0 2 * * * /home/kees/backup.sh && curl -d "Backup OK" http://localhost:8765/backups

Shell Alias (~/.bashrc):

alias notify='curl -d "$1" http://localhost:8765/${2:-notify}'
# Gebruik: notify "Done!" tasks

πŸ“ Project Structuur

/home/kees/Desktop/Notify/
β”œβ”€β”€ README.md                           # Dit bestand
β”œβ”€β”€ Linux Mint Notificaties Gids.html   # Interactieve HTML gids
β”œβ”€β”€ NTFY_LOCAL_SETUP_PLAN.md           # Implementatieplan
β”œβ”€β”€ NTFY_SETUP_COMPLETE.md             # Gebruikershandleiding
└── BROWSER_NOTIFICATION_BRIDGE.md     # Browser bridge documentatie

/home/kees/.config/ntfy/
β”œβ”€β”€ server.yml                          # ntfy server configuratie

/home/kees/.config/systemd/user/
β”œβ”€β”€ ntfy.service                        # ntfy systemd user service
└── chrome-notify-bridge.service        # Browser bridge systemd service

/home/kees/.local/bin/
β”œβ”€β”€ ntfy                                # ntfy binary (62MB)
└── chrome-notification-bridge.py       # Browser notification bridge script

/home/kees/scripts/
β”œβ”€β”€ disk_monitor.sh                     # Schijfruimte monitor
β”œβ”€β”€ notify_on_complete.sh               # Command wrapper
β”œβ”€β”€ backup_notify.sh                    # Backup notificaties
└── nginx_reload_notify.sh              # Nginx reload met notificatie

πŸ”§ Technische Details

Systeem Informatie

  • OS: Linux Mint 22.3 (Cinnamon)
  • Kernel: 6.8.0-90-generic
  • Architecture: x86_64
  • Go Version: 1.22.2 (geΓ―nstalleerd)

ntfy Server Configuratie

base-url: "http://localhost:8765"
listen-http: "127.0.0.1:8765"
cache-file: "/home/kees/.cache/ntfy/cache.db"
auth-default-access: "read-write"
cache-duration: "12h"
log-level: "info"
enable-login: false

Poort Keuze: 8765 gekozen om conflicten te vermijden met:

  • Poort 8080: Nginx/andere webservers
  • Poort 8000: Development servers
  • Poort 3000: Node.js/React dev servers

Beveiliging

Huidige Setup (Lokaal Only):

  • βœ… Bindt alleen op 127.0.0.1 (localhost)
  • βœ… NIET toegankelijk vanaf netwerk
  • βœ… Geen authenticatie nodig (lokaal gebruik)
  • βœ… Rate limiting uitgeschakeld voor localhost

Voor Netwerktoegang: Zie NTFY_SETUP_COMPLETE.md voor instructies om authenticatie en netwerktoegang in te schakelen.

πŸ“– Gebruik Cases

Voor Developers

  • βœ… Build notificaties (npm run build && curl ...)
  • βœ… Test suite resultaten
  • βœ… Git commit hooks
  • βœ… Deployment notificaties
  • βœ… CI/CD pipeline updates

Voor Sysadmins

  • βœ… Server monitoring (CPU, disk, memory)
  • βœ… Backup status
  • βœ… Service restarts
  • βœ… Nginx config changes
  • βœ… Cron job resultaten
  • βœ… System updates

Voor Everyday Use

  • βœ… Long-running task completion
  • βœ… Download voltooiing
  • βœ… Reminder notificaties
  • βœ… Custom scripts en automation

πŸ” Troubleshooting

Server Problemen

# Check service status
systemctl --user status ntfy.service

# Bekijk logs
journalctl --user -u ntfy.service -n 50

# Test connectie
curl http://localhost:8765/v1/health

Client Problemen

Ntfyr toont geen notificaties:

  1. Check of Ntfyr verbonden is met http://localhost:8765
  2. Verifieer dat je geabonneerd bent op het juiste topic
  3. Test met: curl -d "Test" http://localhost:8765/test
  4. Check Cinnamon notificaties: Systeeminstellingen β†’ Notificaties

Poort conflict: Als poort 8765 in gebruik komt, wijzig in ~/.config/ntfy/server.yml:

listen-http: "127.0.0.1:9876"  # Nieuwe poort
base-url: "http://localhost:9876"

Zie de volledige Troubleshooting gids voor meer oplossingen.

πŸ“š Externe Resources

ntfy Documentatie

Ntfyr Client

Related Standards

πŸŽ“ Leerpad

Beginnend:

  1. Lees de HTML gids
  2. Probeer basis notificaties: curl -d "Test" http://localhost:8765/test
  3. Configureer Ntfyr en abonneer op topics

Gevorderd: 4. Gebruik de helper scripts in ~/scripts/ 5. Integreer notificaties in je eigen scripts 6. Voeg cron jobs toe met notificaties

Expert: 7. Maak custom monitoring scripts 8. Integreer met CI/CD pipelines 9. Verken geavanceerde features (attachments, actions)

⚑ Tips & Tricks

Verschillende Topics Gebruiken

Organiseer notificaties met topics:

  • monitoring - System metrics
  • backups - Backup status
  • deployments - Deploy notificaties
  • git - Git gebeurtenissen
  • alerts - Urgente berichten
  • tasks - Taak voltooiingen

In Ntfyr kun je selectief topics aan/uit zetten!

Prioriteiten Gebruiken

# Laag (1) - Groene notificatie, geen geluid
curl -H "Priority: min" -d "Info bericht" http://localhost:8765/info

# Normaal (3) - Standaard notificatie
curl -H "Priority: default" -d "Normaal bericht" http://localhost:8765/test

# Hoog (4) - Oranje, met geluid
curl -H "Priority: high" -d "Belangrijk!" http://localhost:8765/alerts

# Urgent (5) - Rood, blijft zichtbaar
curl -H "Priority: urgent" -d "CRITICAL!" http://localhost:8765/alerts

Emoji Tags Combineren

Maak notificaties visueel herkenbaar:

curl -H "Tags: white_check_mark,rocket" -d "Deploy OK" http://localhost:8765/deployments
curl -H "Tags: x,rotating_light" -d "Error!" http://localhost:8765/monitoring
curl -H "Tags: floppy_disk,white_check_mark" -d "Backup OK" http://localhost:8765/backups

πŸ”„ Updates & Onderhoud

ntfy Server Updaten

# Check huidige versie
~/.local/bin/ntfy --help | grep ntfy

# Download nieuwe versie
cd /tmp
wget https://github.com/binwiederhier/ntfy/releases/latest/download/ntfy_linux_amd64.tar.gz

# Vervang binary
tar xzf ntfy_linux_amd64.tar.gz
mv ntfy_*/ntfy ~/.local/bin/

# Herstart service
systemctl --user restart ntfy.service

Ntfyr Updaten

flatpak update io.github.tobagin.Ntfyr

Cache Opschonen

# Bekijk cache grootte
du -sh ~/.cache/ntfy/

# Optioneel: verwijder oude berichten (server moet gestopt zijn)
systemctl --user stop ntfy.service
rm ~/.cache/ntfy/cache.db
systemctl --user start ntfy.service

🀝 Bijdragen

Dit is een persoonlijk project, maar suggesties zijn welkom!

Verbeteringen toevoegen:

  1. Fork dit project
  2. Maak nieuwe scripts in ~/scripts/
  3. Update documentatie
  4. Deel je use cases

πŸ“œ Licentie

  • ntfy: Apache License 2.0 & GPLv2
  • Ntfyr: Open source (check GitHub)
  • Dit project: Vrij te gebruiken voor persoonlijke doeleinden

πŸ™ Credits


Versie: 1.0 Datum: 2026-01-23 Laatste Update: ntfy 2.12.0 geΓ―nstalleerd op poort 8765

Quick Links:

Status: 🟒 Operationeel

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 2

  •  
  •  

Languages