feat: Gitea Webhook, IMAP, Settings & Deployment docs

- Webhook route and Gitea integration
- IMAP service and Nextcloud/Porkbun setup docs
- Settings UI improvements and API updates
- SSH/Webhook fix prompt for emailsorter.webklar.com
- Bootstrap, config and AI sorter updates
This commit is contained in:
2026-01-31 15:00:00 +01:00
parent 7e7ec1013b
commit cbb225c001
24 changed files with 2173 additions and 32 deletions

View File

@@ -146,7 +146,19 @@ tail -f server/logs/webhook.log
- ✅ Prüfe, ob der Server erreichbar ist (`curl https://emailsorter.webklar.com/api/webhook/status`)
- ✅ Prüfe Gitea-Logs: **Settings** → **Webhooks** → **Delivery Log**
### "Ungültige Webhook-Signatur" (401)
### 502 Bad Gateway (von nginx)
Nginx meldet 502, wenn das Backend (Node/PM2) nicht antwortet oder abstürzt.
- ✅ **Backend läuft:** `pm2 list` Prozess muss „online“ sein
- ✅ **Backend neu starten:** `pm2 restart all` oder `pm2 start ecosystem.config.js`
- ✅ **Logs prüfen:** `pm2 logs` beim nächsten „Test Push“ sofort Fehler ansehen
- ✅ **Health prüfen:** `curl -s -o /dev/null -w "%{http_code}" https://emailsorter.webklar.com/api/health` → sollte `200` sein
- ✅ **Nginx-Upstream:** `proxy_pass` muss auf den richtigen Port zeigen (z.B. `http://127.0.0.1:3000`)
Nach einem Code-Deploy (größeres Body-Limit, robustere Fehlerbehandlung) Backend neu starten: `pm2 restart all`.
### "Ungültige Webhook-Signatur" (401/403)
- ✅ Prüfe, ob `GITEA_WEBHOOK_SECRET` in `server/.env` gesetzt ist
- ✅ Prüfe, ob das Secret in Gitea **genau gleich** ist (keine Leerzeichen!)