LDS Stake Portal

Deployment Overview

Choose between production image-based deployment and local source-based development for the LDS Stake Portal.

The Stake Portal is made up of five independent services. In production, all five run as Docker containers managed by a single Docker Compose file and fronted by Caddy, which handles TLS automatically via Let's Encrypt.

ServiceRolePort
backendFastAPI REST API8000 (internal)
frontendReact SPA + Express proxy3100 (internal)
docs-siteFumadocs documentation site3400 (internal)
caddyReverse proxy + TLS termination80, 443 (public)
discordbotDiscord bot — optional profile8001 (internal)

Choose Your Path

Do not use the development path in production. Running services directly from source without containerization means you are responsible for process supervision, restarts on failure, and keeping Node.js and Python versions consistent.


Production Prerequisites

Before you begin a production deployment, confirm the following are in place.

RequirementDetails
Linux serverUbuntu 22.04 LTS or later recommended
Docker Enginev24+ (includes Docker Compose v2 as docker compose)
Open portsTCP 22 (SSH), 80 (HTTP/ACME), 443 (HTTPS)
Domain nameA registered domain you control
DNS recordsEither three A records (DOMAIN, api.DOMAIN, docs.DOMAIN) pointing to your server IP, or a single A record for DOMAIN plus a wildcard CNAME (*.DOMAIN) if using Cloudflare proxy

DNS must resolve to your server before you start the stack for the first time. Caddy provisions Let's Encrypt TLS via HTTP-01 ACME challenge, which requires port 80 to be publicly reachable. Cloudflare proxy is supported — see the Docker Deployment guide for both DNS paths and the Cloudflare SSL/TLS mode requirement.


Development Prerequisites

RequirementVersionNotes
Node.js18 or laterRequired for the frontend
Python3.11 or laterRequired for backend and Discord bot
uvLatestPython package manager — install here

What Happens on First Boot

When the backend starts against an empty database it automatically bootstraps the portal. No manual SQL or seed scripts are required. See First Run and Bootstrap for the full walkthrough, including how to configure your wards and complete the initial admin login.


Further Reading

On this page