Snapshot both servers: the VPS catalog moves to server/vps, the home server joins as server/home

The catalog in server/containers had drifted from the VPS. Eleven compose
files and twelve units no longer matched what runs, and two running
services, Gbrown_Agent and BillTracker, were missing. server/vps is now a
copy of the live files, and panama-server reads from it.

server/home holds the home server's services in the same shape. They still
run under Docker, so the podman units there are drafts for a later move, and
nothing installs from that tree. PostHog, Sentry and Plausible are checkouts
of upstream repositories. Only their local files are kept, next to an
UPSTREAM file naming the repository and the exact commit.

Every secret in both trees is a ${VAR} reference named in .env.example, or
CHANGE_ME in files that are not compose files. The live servers still hold
some of those values inline, so a live file can differ from its copy on
those lines alone. Existing .env.example files keep their comments, with new
keys appended at the end.

The ignore rules and the secrets contract now cover both trees, plus the
volume/ and volumes/ directories the home server uses.
This commit is contained in:
Gabriel Brown committed 2026-10-06 10:52:47 -04:00
1 parent a664cf68f5
commit 913a57f8a6
146 files changed
+5258 -354

No files matched your search

+48
View File
@@ -0,0 +1,48 @@
#!/usr/bin/env bash
#
# Fedora-native replacement for posthog/bin/upgrade-hobby.
#
# Upstream's script is unusable here: it calls apt-get, re-downloads the v1
# `docker-compose` binary, and overwrites compose.yml from the repo (throwing
# away this server's nginx-proxy-manager and port changes). This does the same
# work using dnf-era tooling and replays the local patches afterwards.
#
set -euo pipefail
cd "$(dirname "$0")/.."
echo "==> Refreshing the PostHog checkout"
git -C posthog fetch origin
git -C posthog reset --hard origin/master
echo " now on $(git -C posthog rev-parse --short HEAD)"
echo "==> Refreshing compose files and re-applying local patches"
cp posthog/docker-compose.base.yml docker-compose.base.yml
cp posthog/docker-compose.hobby.yml compose.yml
cp posthog/.env.services .env.services
bin/apply-local-patches.py compose.yml
docker compose config >/dev/null && echo " compose config OK"
echo "==> Refreshing the GeoIP database"
curl -sL 'https://mmdbcdn.posthog.net/' --http1.1 | brotli --decompress > share/GeoLite2-City.mmdb
echo "{\"date\": \"$(date +%F)\"}" > share/GeoLite2-City.json
chmod 644 share/GeoLite2-City.mmdb share/GeoLite2-City.json
echo "==> Pulling images"
docker compose pull
echo "==> Checking async migrations against the new version"
docker compose up -d db redis7 clickhouse
docker compose run --rm asyncmigrationscheck
echo "==> Restarting the stack"
docker compose up -d --remove-orphans
# web, worker and temporal-django-worker apply compose/local-patches.py on start.
# Surface the result so an upstream change that breaks a patch is not missed.
echo "==> Local source patches"
sleep 15
docker compose logs --since 5m web worker temporal-django-worker 2>&1 | grep LOCAL-PATCH || \
echo " no LOCAL-PATCH lines yet, check: docker compose logs web worker | grep LOCAL-PATCH"
echo
echo "Done. Watch the migrations with: docker compose logs -f web"