From 81ce5ab8811c9c2bacf7b68c768f0ee770b1fe58 Mon Sep 17 00:00:00 2001 From: JSONbored <49853598+JSONbored@users.noreply.github.com> Date: Sat, 4 Jul 2026 12:24:27 -0700 Subject: [PATCH] docs(selfhost): align release upgrade/rollback docs with deploy scripts (#1829) The Upgrade flow and Rollback sections on the self-host releases doc described a generic docker compose pull/up cycle instead of the two deploy scripts the repo actually ships (deploy-selfhost-image.sh, deploy-selfhost-prebuilt.sh), which add input validation and a health-check wait loop a bare compose invocation skips. Rollback also didn't mention that migrations are forward-only, so reverting the app image after a migration has already run leaves the schema ahead of the code. --- .../src/routes/docs.self-hosting-releases.tsx | 43 +++++++++++++++---- 1 file changed, 35 insertions(+), 8 deletions(-) diff --git a/apps/gittensory-ui/src/routes/docs.self-hosting-releases.tsx b/apps/gittensory-ui/src/routes/docs.self-hosting-releases.tsx index fa667cbbba..c76a89df1a 100644 --- a/apps/gittensory-ui/src/routes/docs.self-hosting-releases.tsx +++ b/apps/gittensory-ui/src/routes/docs.self-hosting-releases.tsx @@ -82,18 +82,35 @@ docker pull ghcr.io/jsonbored/gittensory-selfhost:latest`}
scripts/deploy-selfhost-image.sh (or rebuild the
+ checkout with scripts/deploy-selfhost-prebuilt.sh) — both restart only the{" "}
+ gittensory service (--no-deps) and wait for it to report{" "}
+ healthy before returning, instead of a bare docker compose up -d{" "}
+ that returns as soon as the container starts.
+ /ready, logs, queue metrics, and one test PR.
GITTENSORY_IMAGE; the prebuilt script derives SENTRY_RELEASE/
+ GITTENSORY_VERSION from the checked-out commit (
+ git rev-parse --short=8 HEAD) unless you set SENTRY_RELEASE{" "}
+ yourself. A plain{" "}
+ docker compose pull gittensory && docker compose up -d gittensory still
+ works, but skips the health-check wait loop and input validation both scripts provide.
+ @@ -118,10 +135,20 @@ docker compose up -d gittensory`}
- Roll back by pinning the prior image tag and recreating the container. Database migrations
- can make rollback harder, so keep backups and read release notes before upgrading a live
- maintainer instance.
+ There is no dedicated rollback command. Roll back by re-running{" "}
+ scripts/deploy-selfhost-image.sh pinned to the prior image tag or digest (or{" "}
+ scripts/deploy-selfhost-prebuilt.sh against an older checkout) — the same
+ script you upgrade with, pointed backward.
scripts/check-migrations.mjs and{" "}
+ migrations/ only ever add forward). If a migration already ran forward before
+ you need to roll back, reverting the app image does not revert the schema — the rolled-back
+ code now runs against a newer schema than it expects. Keep backups and read release notes
+ for migration changes before upgrading a live maintainer instance, and treat a
+ post-migration rollback as a case that needs a manual schema/data plan, not just an image
+ swap.
+