Install a server
These steps give you a working server on port 3000. You can try it on localhost straight away. To use it from phones and watches, carry on to Set up HTTPS afterward.
From the published image
Section titled “From the published image”This is the way to run a real server.
-
Make a folder on the Docker host, and put these two files from the repository in it:
compose.yaml, and.env.examplesaved as.env. -
Make a secret. It signs sign-in sessions, and has to be at least 32 characters.
Terminal window openssl rand -base64 32 -
Edit
.env. SetAUTH_SECRETto that secret, and choose the image and a database password:.env LAWFIVE_IMAGE=ghcr.io/lawfive/lawfive:latestAUTH_SECRET=the-secret-you-just-madePOSTGRES_PASSWORD=a-password-of-your-own -
Start it:
Terminal window docker compose pulldocker compose up -d -
Read the setup code from the logs:
Terminal window docker compose logs server -
Open
http://localhost:3000, or the machine’s address, and follow the setup wizard.
Image tags
Section titled “Image tags”| Tag | What it is |
|---|---|
latest |
The newest release |
A version, such as 2026.11.12 |
One release, to stay on it |
edge |
The newest build from main, ahead of the next release (what the hosted service runs) |
sha-<commit> |
The build of one commit |
Each release’s notes, with anything to do before upgrading, are on GitHub’s releases page.
From source
Section titled “From source”To build the image yourself, clone the repository and work from its root:
cp .env.example .env # then set AUTH_SECRETdocker compose up -d --builddocker compose logs serverLeave LAWFIVE_IMAGE unset. An image you build this way shows its version as dev unless you pass --build-arg LAWFIVE_VERSION=… --build-arg LAWFIVE_COMMIT=….
Just trying it out
Section titled “Just trying it out”To look around with sample data, with no database or Docker, see the demo server.
Check it works
Section titled “Check it works”Once it’s behind HTTPS:
curl https://lawfive.example.com/healthanswersok.- The address opens in a browser with no certificate warning, and Settings → Server → HTTPS says it’s set up correctly.
- You can sign in with the admin account from the wizard.
- A phone app signs in with Use another server and your address. See Phones.
- A watch links from Link a watch. See Watches.
- Finish the setup wizard
- Set up HTTPS, which watches and phones need