Files
Convivo/docs/deployment.md
T
d894339821 docs: remove credentials from deployment.md + document co-authors
Co-authored-by: Stephan Charles <[email protected]>
Co-authored-by: Amelia Hernandez <[email protected]>
Co-authored-by: Markus Franz <[email protected]>
Co-authored-by: Sabrina Hota <[email protected]>
Co-authored-by: Nilüfer Doğan <[email protected]>
2026-10-29 22:08:04 +01:00

109 lines
4.6 KiB
Markdown
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
# Deployment — VM Access
Convivo currently runs **entirely on localhost** (see
[backend/supabase-core.md](./backend/supabase-core.md) and
[backend/docker.md](./backend/docker.md)). This page documents the **remote VM** that is
the intended deployment target for the `appe.at` subdomains
(`convivo.appe.at`, `admin.appe.at`, `db.appe.at`).
> **Status:** the VM is reachable (last validated 2026-08-25). The full Convivo
> stack is **deployed and running**
> on the VM (see [Running services](#running-services)). DNS, TLS, and the
> reverse proxy for the `appe.at` subdomains are **not** set up yet — see
> [next-steps.md](./next-steps.md#cross-cutting--later).
## Credentials
Credentials (VM SSH password, Portainer admin, NPM admin) are **not stored in
this repository**. They are kept in a secure store outside the repo — ask the
project maintainer for access. VM host: `68.210.96.53`, SSH user `APPE`.
## Portainer
Portainer CE runs on the VM (`:9000` web, `:9443` HTTPS).
> **Setup token:** a fresh Portainer install (after clearing the `portainer_data`
> volume) requires a one-time **setup token** to create the admin account. It is
> printed in the container logs: `docker logs portainer | grep setup_token`.
> The token rotates on every (re)start, so read it from the logs at setup time.
## Nginx Proxy Manager (NPM)
NPM runs on the VM. In this instance the **admin UI is served on port 81**
(not the default 8181 — the container's `production.conf` puts the admin
interface on 81, and 8181/8182 are unbound).
> **Fresh install:** NPM's data (admin login + proxy hosts) lives in the
> `npm_data` volume (mounted at `/data`). To reset it, stop the container, wipe
> the volume contents, and restart — the API then reports `"setup": false` and
> the admin UI shows the "Create admin account" screen.
## Running services
The full stack is deployed on the VM (Docker). Host-exposed ports:
| Container | Host port(s) | What it is |
|---|---|---|
| `convivo-app` | 3000 | Attendee PWA |
| `convivo-admin` | 3001 | APPE Admin console |
| `convivo-sidecar` | 3002 | Sessionize sync sidecar |
| `supabase_kong_Convivo` | 54321 | Kong API gateway |
| `supabase_db_Convivo` | 54322 | Postgres 17 |
| `supabase_studio_Convivo` | 54323 | Supabase Studio |
| `supabase_inbucket_Convivo` | 54324 | Mailpit (email capture) |
| `supabase_analytics_Convivo` | 54327 | Logflare analytics |
| `portainer` | 9000, 9443 | Portainer CE |
| `nginx-proxy-manager` | 81 (admin UI + proxied sites), 8181–8182 (published but unbound) | Nginx Proxy Manager |
## Connecting
**Key-based auth is set up** (the developer's `~/.ssh/id_ed25519` public key is
in `[email protected]:~/.ssh/authorized_keys`). On a machine with that key, no
password is needed:
```bash
ssh [email protected]
# or, with the `convivo-vm` alias in ~/.ssh/config:
ssh convivo-vm
```
Password fallback (if the key is unavailable): `ssh [email protected]` and use
the password from the secure store (see [Credentials](#credentials)).
### Port-forward tunnel (access the stack from a laptop)
The full stack runs on the VM. To reach it from a local machine, forward the
service ports over SSH (no password needed with the key above):
```bash
ssh -N -L 3000:127.0.0.1:3000 -L 3001:127.0.0.1:3001 -L 3002:127.0.0.1:3002 \
-L 54321:127.0.0.1:54321 -L 54322:127.0.0.1:54322 -L 54323:127.0.0.1:54323 \
-L 54324:127.0.0.1:54324 -L 54327:127.0.0.1:54327 \
-L 9000:127.0.0.1:9000 -L 9443:127.0.0.1:9443 \
-L 8081:127.0.0.1:81 \
-o ServerAliveInterval=30 -o ServerAliveCountMax=3 convivo-vm
```
| Local URL | Service |
|---|---|
| http://localhost:3000 | Convivo attendee app |
| http://localhost:3001 | APPE Admin |
| http://localhost:3002/health | Sync sidecar |
| http://localhost:54321 | Kong API |
| `postgresql://postgres:postgres@localhost:54322/postgres` | Postgres |
| http://localhost:54323 | Supabase Studio (`postgres`/`postgres`) |
| http://localhost:54324 | Mailpit |
| http://localhost:54327 | Logflare |
| http://localhost:9000 | Portainer CE (login from the secure store) |
| http://localhost:8081 | NPM admin UI (login from the secure store) |
> NPM's admin UI is on the VM's port **81**, forwarded to local **8081** (81 is
> a privileged port and can't be bound locally without root). The apps proxy
> their Supabase calls to Kong over the shared Docker network, so only the app
> ports are needed for the UI; `54321`/`54322`/`54323` are for direct
> API/DB/Studio access.
> **Security note:** never commit credentials to this repository. Key-based SSH
> auth is the preferred path. Credentials that were previously committed have
> been purged from the git history and should be rotated.