Installation¶
Recommended Usage¶
The easiest way to run Relay is via the OUCHnet Docker image:
docker pull git.thc420.dev/ouch/thelounge:latest
docker run -d \
--name relay \
-p 9000:9000 \
-v ~/.relay:/var/opt/relay \
--restart always \
git.thc420.dev/ouch/thelounge:latest
Existing data from ~/.thelounge//var/opt/thelounge (pre-rename installs) is picked up automatically if the new path is empty — no manual migration needed.
Or with Docker Compose:
docker compose up -d
Example docker-compose.yml:
services:
relay:
image: git.thc420.dev/ouch/thelounge:latest
container_name: relay
ports:
- "9000:9000"
volumes:
- ./data:/var/opt/relay
restart: always
Adding the first admin user¶
Option 1: Web setup (recommended)¶
The first time Relay starts with no user accounts, it prints a one-time setup token to the container logs:
docker logs relay
Look for a line like:
No users exist yet. To create the first admin account, open the web UI and enter this one-time setup token: <token>
Open the web UI in your browser — you'll land on a setup page automatically. Enter a username, password, and the token from the logs to create the admin account.
Note
The setup page and token are permanently disabled the instant the account is created, so this only works once per install.
Option 2: Command line¶
If you'd rather not use the web setup page, create the initial admin account with relay add --admin:
docker exec -it relay relay add --admin <username>
docker compose exec relay relay add --admin <username>
Both commands prompt for a password. The new account will be available immediately — no restart needed. Using this method before ever opening the web UI means the setup page will never appear for that install.
Running stable releases¶
Please refer to the install and upgrade documentation on the upstream The Lounge website for all available installation methods.
Running from source¶
Relay requires latest Node.js LTS version or more recent.
The following commands install and run Relay from source:
git clone <your-relay-repository-url>
cd relay
npm install
NODE_ENV=production npm run build
npm start
When installed like this, the relay executable is not created. Use node index <command> to run commands.
Not production-ready
While it is the most recent codebase, this is not production-ready. Run at your own risk. It is also not recommended to run this as root.