2.5 KiB
2.5 KiB
Deployment notes — Family Home Lab
Domains
- Public zone
lab.audasmedia.com.au→144.6.86.11(router) →.35Caddy. - No Pi-hole local records needed.
*.home.labis deprecated (not a registered TLD).
Caddy (.35)
- SSH:
ssh sam@192.168.20.35 - Locate the running Caddy config (Docker container on .35).
- Append
deploy/caddy/Caddyfile.snippetcontents to the Caddyfile. - Reload:
docker exec <caddy> caddy reload --config /etc/caddy/Caddyfile - Verify Caddy can obtain Let's Encrypt certs (ports 80/443 forwarded on router — already working for omniroute/gitea domains).
Host (.13)
- Compose project:
/home/sam/Docker/Containers/family-home-lab/(created during build). - Data:
/mnt/data/family-home-lab/(garage-data, garage-meta, shared-media, dsh/). - Backup: add
/mnt/data/family-home-lab/to Borg sources in/etc/nixos/backup.nix.
Ports (on .13)
| Port | Service |
|---|---|
| 8500 | Portal (FastAPI) |
| 8487 | Photopea (→ container 8887) |
| 8083 | Video editor (kdenlive) — 8081 was taken by airflow-webserver |
| 8084 | Audio editor (audacity) — 3000 was taken by a NixOS service |
| 3900/3902 | Garage (S3/admin) |
| 3081–3084 | dsh instances (other agent) |
Order of operations
- Build portal + compose stack (this repo) →
docker compose up -don .13 - Apply Caddy snippet on .35
- Test
https://console.lab.audasmedia.com.au - Deploy tool containers one at a time, verifying each URL
- dsh agent deploys its instances and coordinates token handoff
First run (portal)
Portal auto-creates the DB tables and, if the users table is empty, seeds the
admin from ADMIN_USERNAME/ADMIN_PASSWORD in .env (Sam, by default).
cd /home/sam/Docker/Containers/family-home-lab
docker compose up -d
# first admin already created on startup; create the rest in the UI at /admin
Garage provisioning (S3 buckets + access keys)
After Garage is up, create buckets/keys from inside the container:
# env for the garage CLI
G=('docker compose exec -T garage garage --config /etc/garage.toml')
# main service key for the portal
KEY_ID=$($G key import --name portal - <<< "$(cat .env | grep S3_ACCESS | cut -d= -f2)")
# buckets
for b in sam jo harry finn shared-media; do $G bucket create "$b"; done
# allow the portal key to access every bucket
for b in sam jo harry finn shared-media; do $G bucket allow --read --write "$b" --key portal; done
Symmetry: ensure S3_ACCESS_KEY/S3_SECRET_KEY in
.envmatch whatkey importregisters, else portal uploads will 403.