fix(upgrades): close upgrade system definition-of-done gaps #87
Merged
wasabi opened 2 days ago

Summary

Closes the remaining upgrade-system Definition-of-Done gaps identified after KI-86.

Changes

  • Injects the checked-out git SHA into Compose application services and verifies version/SHA from inside the Compose network.
  • Adds scripts/verify-upgrade.sh and makes it the default post-upgrade verifier.
  • Removes the normal upgrade backup bypass; every upgrade now creates a checkpoint.
  • Moves the canonical pilot organization out of normal/reference seeding and keeps it in seed-pilot.sh.
  • Extends advisory locking to migration tracking initialization and legacy reconciliation.
  • Adds disposable PostgreSQL and ClickHouse checkpoint restore coverage.
  • Exercises the explicit rollback path in CI using isolated databases.
  • Adds CI configuration for backup encryption and application SHA verification.

Verification

  • KOKONUT_ALLOW_PLAINTEXT_ENV=true .venv/bin/python -m pytest tests/test_migration.py tests/test_upgrade.py tests/test_upgrade_integration.py -q
  • 26 passed, 1 expected local-only integration skip.
  • Shell syntax validation passed for upgrade, verifier, backup, restore, rollback, and seed scripts.
  • Ruff passed for changed Python files.
  • Development and production Compose configurations validated.
  • CI-only integration test provisions isolated PostgreSQL and ClickHouse databases, creates a verified checkpoint, drops/recreates both, and restores them through the rollback path.
Commits were merged into target branch
1/1
Submitter wasabi
Target main
Source fix/upgrade-dod-gaps
Jobs
Merge Strategy
Create Merge Commit
Watchers (1)
Reference
pull request KI-87
Please wait...
Connection lost or session expired, reload to recover
Page is in error, reload to recover