Fixes:
- Update dependencies within their ranges: npm audit reported 8
vulnerabilities (proxy-addr, multer, body-parser, undici...), now 0.
- Close open connections on shutdown: an open jukebox page kept its
/api/events stream alive, so every restart waited for the 10 s
forced exit and ended with code 1.
- Restore the ANSI escape characters of the game servers message, lost
in a269824 (the status showed "[2;32mOnline[0m" as plain text). They
are now written as \u001b so they cannot silently disappear again.
- Rename MusicQueue.listeners(), which shadowed EventEmitter's own
listeners(eventName), to humanListeners().
- Deploy: check the VM's SSH host key (new DEPLOY_KNOWN_HOSTS secret)
instead of StrictHostKeyChecking=no; run checks on push only, since
PR branches are already checked by their push.
Commands:
- /listcommand is built from the loaded commands and their descriptions.
- /deletemsgs reports messages older than 14 days that it cannot delete.
- Vocal commands act on the caller's voice channel, falling back to
VOICE_CHANNEL_ID.
- /maketeam accepts comma-separated names, so names can contain spaces.
- The game servers message is edited whenever its content changes, and
a failed first update is retried instead of stopping the refresh.
Cleanup:
- Shared command loader (src/loadCommands.js); drop the unused
"[disabled]" folders mechanism and the NODE_ENV requirement.
- SHINUWA_USER_ID becomes OWNER_USER_ID (the old name still works).
- One shuffle helper instead of three copies; remove dead code
(validateAudioFile, PORT fallback, needless async).
- README: prerequisites first, consistent Node version, deploy secrets.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
24 lines
1.1 KiB
Text
24 lines
1.1 KiB
Text
DISCORD_GUILD_ID=
|
|
# Personne qui gère les serveurs de jeux, mentionnée dans leur message (ancien nom : SHINUWA_USER_ID).
|
|
OWNER_USER_ID=
|
|
WEB_SERVER_PORT=3000
|
|
WEB_API_KEY=
|
|
DISCORD_APPLICATION_ID=
|
|
DISCORD_TOKEN=
|
|
VOICE_CHANNEL_ID=
|
|
TEXT_CHANNEL_ID=
|
|
GAME_SERVERS_MESSAGE_ID=
|
|
# Facultatif : proxys de confiance (adresse IP de Caddy en production), « loopback » par défaut.
|
|
WEB_TRUSTED_PROXIES=
|
|
# Facultatif : clé des applications de confiance (Sokko TCG) ; sans elle, pas de messages privés.
|
|
NOTIFICATIONS_API_KEY=
|
|
# Facultatif : lien d'invitation temporaire publié par /invitation sans option « lien ».
|
|
INVITE_LINK=
|
|
# Facultatif : connexion avec Discord sur la page web (active si les trois sont définies).
|
|
# Secret OAuth2 de l'application (portail développeur Discord, onglet OAuth2).
|
|
DISCORD_CLIENT_SECRET=
|
|
# Adresse publique du site, sans / final (https://…). Ajouter <adresse>/auth/discord/callback
|
|
# aux « Redirects » OAuth2 de l'application.
|
|
WEB_PUBLIC_URL=
|
|
# 32 caractères au moins (openssl rand -hex 32) ; le changer déconnecte tout le monde.
|
|
SESSION_SECRET=
|