domain updates
CI / Lint, types, build, tests (push) Canceled after 0s
CI / Docker images build (push) Canceled after 0s

This commit is contained in:
olehhapuk
2026-12-03 12:27:03 +02:00
parent d47863f653
commit ea1f5f8b16
3 changed files with 42 additions and 24 deletions
+4 -2
View File
@@ -38,10 +38,10 @@ pnpm --filter api test:e2e # API end to end; needs the containers abo
## Deploying
`docker-compose.yml` runs the whole app on one server: Caddy in front (HTTPS with certificates it fetches itself), the web app, the API, PostgreSQL, Redis and LiveKit.
`docker-compose.yml` runs the app on one server: the web app, the API, PostgreSQL, Redis and LiveKit. The way in is the server's own Caddy, a separate compose project that other projects share: it gets the HTTPS certificates and reaches this one over the external Docker network `web`.
1. Point three DNS names at the server: `example.com`, `api.example.com` and `livekit.example.com` (yours in place of `example.com`). The web app and the API must share a parent domain like this: the session cookie is only sent between pages of one site.
2. Open the firewall for 80 and 443 (TCP), 443 (UDP), and for calls 7881 (TCP) and 7882 (UDP).
2. Let 80 and 443 (TCP) through to Caddy, and for calls 7881 (TCP) and 7882 (UDP) through to this server: on the firewall, and on the router if the server is behind one.
3. On the server, in a checkout of this repository:
```bash
@@ -49,6 +49,8 @@ pnpm --filter api test:e2e # API end to end; needs the containers abo
docker compose up -d --build
```
4. Mount `deploy/Caddyfile` into the shared Caddy as one of its site files (`/etc/caddy/sites/electro4ort.caddy`) and restart it. The three names are written out in that file: change them there if `DOMAIN` is not `electro4ort.com.ua`.
To update: `git pull`, then `docker compose up -d --build` again. Migrations are applied by the `migrate` service before the new API starts.
What to know before relying on it: