Setup-Seite: Kanal-Auswahl, Feed-Regeln und Status im Webinterface

- Settings-Tabelle in SQLite; Env-Variablen nur noch Fallback, Änderungen greifen sofort
- /settings (Admin): Devlog-/Commit-Kanal als Dropdown aus allen sichtbaren Textkanälen,
  je mit Test-senden-Button
- Commit-Feed-Regeln: an/aus, Branch-Filter, ignorierte Repos (archiviert wird immer,
  gefiltert wird nur das Posten; ignorierte Repos komplett übersprungen)
- Status-Panel: Bot-Tag, Uptime, Devlog-/Commit-Zahlen, DB-Größe
- API: GET/PUT /api/settings, POST /api/settings/test/:target (alles Admin-only)
- COMMIT_CHANNEL_ID/DEVLOG_CHANNEL_ID in config optional

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
2026-07-23 10:21:05 +02:00
co-authored by Claude Opus 4.8
parent 71d2bb07f1
commit ae5732a61b
14 changed files with 516 additions and 23 deletions
+5 -4
View File
@@ -19,15 +19,16 @@ export const config = {
discordGuildId: process.env.DISCORD_GUILD_ID || null,
// Devlog-Archiv (Feature 3)
// Kanal, in den der Bot die Devlogs postet (und den er mitliest)
devlogChannelId: required('DEVLOG_CHANNEL_ID'),
// Kanal-Defaults — können über die Settings-Seite im Webinterface
// überschrieben werden (DB gewinnt, Env ist Fallback)
devlogChannelId: process.env.DEVLOG_CHANNEL_ID || null,
// Secret im Pfad des Devlog-Endpoints: /webhooks/devlog/<secret>
// (steckt in der URL in tools/.devlog_webhook im EcoGame-Repo)
devlogPostSecret: required('DEVLOG_POST_SECRET'),
// Commit-Feed (Feature 2)
// Kanal, in den Push-Embeds gepostet werden
commitChannelId: required('COMMIT_CHANNEL_ID'),
// Kanal, in den Push-Embeds gepostet werden (Default, siehe oben)
commitChannelId: process.env.COMMIT_CHANNEL_ID || null,
// Shared Secret — muss identisch im Gitea-Webhook eingetragen sein
giteaWebhookSecret: required('GITEA_WEBHOOK_SECRET'),