ops: migrate legacy event sequences safely
This commit is contained in:
@@ -41,3 +41,28 @@ Verify the coordinator at `GET /v1/admin/diagnostics` with the normal admin
|
||||
credential: its `build` object is the coordinator provenance. `GET
|
||||
/v1/federation/workers` shows every worker's `build`, supported projects, and
|
||||
worker-local health without SSH.
|
||||
|
||||
For the Docker coordinator deployment, provide the same provenance as build
|
||||
arguments (the Dockerfile intentionally cannot read `.git` from its build
|
||||
context):
|
||||
|
||||
```sh
|
||||
revision=$(git rev-parse HEAD)
|
||||
build_time=$(date -u +%Y-%m-%dT%H:%M:%SZ)
|
||||
dirty=false; test -z "$(git status --porcelain)" || dirty=true
|
||||
docker compose build \
|
||||
--build-arg BUILD_REVISION="$revision" \
|
||||
--build-arg BUILD_TIME="$build_time" \
|
||||
--build-arg BUILD_DIRTY="$dirty" \
|
||||
orchestra-api
|
||||
docker compose up -d --no-deps orchestra-api
|
||||
```
|
||||
|
||||
If a pre-v2 event log has the historical repeated-`seq=1` prefix, the current
|
||||
coordinator intentionally refuses to replay it. Stop every coordinator using
|
||||
the data directory and run the explicit, backup-preserving migration before
|
||||
deploying the current image:
|
||||
|
||||
```sh
|
||||
orchestra-migrate -data /var/lib/orchestra/data -confirm
|
||||
```
|
||||
|
||||
Reference in New Issue
Block a user