Feat: Push-Notifications vollständig implementiert

- push.py: /vapid-key, /subscribe, /unsubscribe + send_push_to_user/all Helpers
- VAPID Keys in docker-compose.yml (Public + Private)
- Giftköder-Meldung löst automatisch Push an alle Subscriber aus
- ON CONFLICT(endpoint) für idempotentes Re-Subscribe
- Abgelaufene Subscriptions werden bei HTTP 410 auto-gelöscht
This commit is contained in:
rene 2026-04-13 20:47:51 +02:00
parent b8a5dc7a66
commit c721d051c8
3 changed files with 142 additions and 3 deletions

View file

@ -12,6 +12,9 @@ services:
environment:
- DB_PATH=/data/banyaro.db
- MEDIA_DIR=/data/media
- VAPID_PUBLIC_KEY=BMKbFAmpsqJ-eFef_4XJcYpuxPWqBNAoy9buMNnMSa6ijcPzltboHi_YccPKJrUD0isBez-vJIzAgjnLTWkzcC0
- VAPID_PRIVATE_KEY=8PWa9vvwMqtqsJEJGcwmiLhR0_Yl7duVX3wmWiKS878
- VAPID_CONTACT=mailto:admin@banyaro.app
healthcheck:
test: ["CMD", "curl", "-f", "http://localhost:8000/"]
interval: 30s