Bläddra i källkod

docs: record the zeus container upgrade to 2.12.0 and the procedure used

The live smartbotic-automation database on zeus moved from 2.11.3 to 2.12.0
with about 14 s of downtime; the runner and webserver reconnected on their own.
The roadmap section said 'pending' and pointed at a 2.11.4 image that was never
deployed. It now records the upgrade, the rollback container and backup path,
and the procedure, including copying the data as root because the container
writes root-owned files.
fszontagh 1 månad sedan
förälder
incheckning
545ff9896e
1 ändrade filer med 28 tillägg och 18 borttagningar
  1. 28 18
      docs/ROADMAP.md

+ 28 - 18
docs/ROADMAP.md

@@ -208,28 +208,38 @@ the loop guard to `Client::Event::actor`, delete with `removeAs()` /
 `FailureDetail::reason` to HTTP. Their package floor becomes
 `libsmartbotic-db-client (>= 2.12.0)`, and the database must be deployed first.
 
-### 5a-3. Pending: upgrade the zeus `smartbotic-db` container
+### 5a-3. The zeus `smartbotic-db` container: on 2.12.0 since 2026-10-07
 
 The container on zeus is **not a test**: it is the live database of the
 smartbotic-automation stack (`smartbotic-webserver` and `smartbotic-runner`
 connect via `host.docker.internal:9004`, project `smartbotic-automation`; data
-since April). It runs 2.11.3. A nightly cron (`/etc/cron.d/smartbotic-db-backup`,
-03:30 local) stops it, archives data + key to `/data/backups/smartbotic-db/`
-(keeps 14) and starts it again; the automation stack rides through that.
-
-A **2.11.4** runtime image is built and tested but NOT swapped in - since
-superseded: build **2.12.0** the same way instead, because vectorapi 0.5.0
-needs it on any database it talks to
-(`smartbotic-database:2.11.4`, made with the Ubuntu 26.04 recipe in
-`/data/smartbotic-db/build/`: `src-2.11.4/`, `hostbin-2.11.4/`,
-`Dockerfile.2.11.4`). It booted cleanly on a copy of the 2026-10-06 backup
-(`TrivialSuccess`, 10111 docs). The owner has not yet decided whether to swap,
-and 2.12.0 is the version to build now (see above). The swap
-procedure used for every earlier upgrade: snapshot the data directory to
-`/data/smartbotic-db/backups/pre-<ver>-<ts>`, rename the running container to
-`smartbotic-db-<old>-rollback`, start the new image with the same name, ports,
-mounts, `--restart unless-stopped` and `--stop-timeout 120`, then check recovery
-and that both automation containers reconnected.
+since April). A nightly cron (`/etc/cron.d/smartbotic-db-backup`, 03:30 local)
+stops it, archives data + key to `/data/backups/smartbotic-db/` (keeps 14) and
+starts it again.
+
+Upgraded 2.11.3 -> **2.12.0** on 2026-10-07 at 12:44 local, about 14 s of
+downtime: `TrivialSuccess` recovery of 10110 docs, not read-only, runner and
+webserver reconnected on their own. Image `smartbotic-database:2.12.0`, built
+with the Ubuntu 26.04 recipe in `/data/smartbotic-db/build/` (`src-2.12.0/`,
+`hostbin-2.12.0/`, `Dockerfile.2.12.0`) and staged first on a copy of that
+night's backup. Pre-upgrade copy: `/data/smartbotic-db/backups/pre-2.12.0-20261007-124433`.
+Rollback container: `smartbotic-db-2.11.3-rollback`.
+
+The procedure, for the next upgrade:
+1. Build the image with the Ubuntu 26.04 recipe and stage it on a copy of the
+   latest nightly backup on a localhost-only port.
+2. `docker stop -t 120` (graceful, so the final snapshot is written), then copy
+   `data` and `etc` to `backups/pre-<ver>-<ts>` **as root inside a container**,
+   because the container writes root-owned files.
+3. Rename the old container to `smartbotic-db-<old>-rollback` and start the new
+   image under the same name with `--restart unless-stopped --stop-timeout 120
+   -p 9004:9004` and the same two mounts.
+4. Check recovery, that it is not read-only, and that both automation
+   containers reconnected.
+
+A write landing inside the outage fails after the client's short retry window.
+Seen here as the runner's heartbeat being refused for a few seconds; it
+recovered by itself, exactly as it does during the nightly backup stop.
 
 ### 5b-2. Open after the v2.11.4 consumer feedback round