Skip to content

Self-hosted deploy

The v0.5.0 proof path deployed kanade-discord to CT 113, then relayed traffic back to the Windows daemon through a private SSH/systemd path. That path avoids opening the Windows daemon directly to the LAN, but it is still a maintainer transport. Longer-lived deployments should choose a clean private network such as Tailscale, WireGuard, or Cloudflare Tunnel before treating phone-side Discord as always-on production.

The bot environment must include:

DISCORD_BOT_TOKEN
DISCORD_APPLICATION_ID
DISCORD_GUILD_ID
DISCORD_ALLOWED_USER_IDS
KANADE_DAEMON_URL
KANADE_DEFAULT_ACCOUNT_ID
KANADE_DISCORD_BRIDGE_SECRET
KANADE_DISCORD_READY_FILE=/tmp/kanade-discord.ready

Do not commit real env files. Rotate the Discord token and HMAC secret through a secret manager, then restart both the bot and the daemon with matching values.

The bot writes a ready file after Discord login and refreshes it every 60 seconds. Container health uses that heartbeat. If the container turns unhealthy, check the ready file timestamp, daemon reachability, signature secret, and allowlists before restarting.