refactor(backup): name archives bitborg-*, accept gitborg-* until 2026-10-31 #518

Sammanfogat
supernaut sammanfogade 3 incheckningar från feat/465-bitborg-archive-names in i main 2026-10-02 13:14:29 +00:00
Ägare

What

Name new daily archives bitborg-<TS>.tar.age instead of gitborg-<TS>.tar.age, with a dual-match transition.

  • backup_archive_prefixes: [bitborg, gitborg] in group_vars/all/vars.yml. The first entry is what the backup writes; every entry is what consumers match. Remove gitborg after 2026-10-31, when no gitborg-* archive is left in retention.
  • bitborg-backup.sh: archive and .partial names from the first prefix; .partial sweep, local prune and off-site rclone delete --include match every prefix (.tar.age and legacy .tar.enc).
  • bitborg-backup-verify.sh: newest by mtime over every prefix.
  • bitborg-backup-drill.py: lists every prefix and picks the newest by the embedded timestamp. The old max(names) would have ranked gitborg- above bitborg- and restored a stale archive.
  • Runbook: restore steps and the #465 lifecycle XML use bitborg-. A locked bucket is switched to only after this is applied, so it never holds a gitborg-* archive and needs no legacy rule. Cleanup due 2026-10-31 noted.

Host paths, the OS user, volumes and unit names are unchanged (legacy pins, separate migration).

Verification

--syntax-check, ansible-lint 0/0, rendered templates pass bash -n and py_compile, shellcheck info only (pre-existing). Local test: with gitborg-20261001… (older) and bitborg-20261002… (newer), verify, prune and the drill all select the bitborg- archive; a plain name sort picks the stale one.

Apply

Tags backup,backup-drill: redeploys the backup, verify and drill scripts, no unit changes, no restarts. The next 03:30 run writes the first bitborg- archive.

Refs #465

## What Name new daily archives `bitborg-<TS>.tar.age` instead of `gitborg-<TS>.tar.age`, with a dual-match transition. - `backup_archive_prefixes: [bitborg, gitborg]` in `group_vars/all/vars.yml`. The first entry is what the backup writes; every entry is what consumers match. Remove `gitborg` after 2026-10-31, when no `gitborg-*` archive is left in retention. - `bitborg-backup.sh`: archive and `.partial` names from the first prefix; `.partial` sweep, local prune and off-site `rclone delete --include` match every prefix (`.tar.age` and legacy `.tar.enc`). - `bitborg-backup-verify.sh`: newest by mtime over every prefix. - `bitborg-backup-drill.py`: lists every prefix and picks the newest by the embedded timestamp. The old `max(names)` would have ranked `gitborg-` above `bitborg-` and restored a stale archive. - Runbook: restore steps and the #465 lifecycle XML use `bitborg-`. A locked bucket is switched to only after this is applied, so it never holds a `gitborg-*` archive and needs no legacy rule. Cleanup due 2026-10-31 noted. Host paths, the OS user, volumes and unit names are unchanged (legacy pins, separate migration). ## Verification `--syntax-check`, ansible-lint 0/0, rendered templates pass `bash -n` and `py_compile`, shellcheck info only (pre-existing). Local test: with `gitborg-20261001…` (older) and `bitborg-20261002…` (newer), verify, prune and the drill all select the `bitborg-` archive; a plain name sort picks the stale one. ## Apply Tags `backup,backup-drill`: redeploys the backup, verify and drill scripts, no unit changes, no restarts. The next 03:30 run writes the first `bitborg-` archive. Refs #465
supernaut lade till 3 incheckningar 2026-10-02 13:07:19 +00:00
Producers write bitborg-<TS>.tar.age. Consumers (partial sweep, local and
off-site prune, verify, drill) match bitborg-* and gitborg-* through
backup_archive_prefixes. The drill picks the newest by embedded timestamp.

Refs #465
A locked bucket is switched to only after the rename is applied, so it never receives a gitborg-* archive.

Refs #465
Merge remote-tracking branch 'origin/main' into feat/465-bitborg-archive-names
Alla kontroller lyckades
ci / ci (pull_request) Successful in 2m8s
0c42bc68f2
supernaut sammanfogade incheckning d1f53f533b till main 2026-10-02 13:14:29 +00:00
supernaut tog bort grenen feat/465-bitborg-archive-names 2026-10-02 13:14:30 +00:00
Logga in för att delta i denna konversation.
Inga granskare
Ingen milstolpe
Inget projekt
Inga tilldelade
1 deltagare
Notiser
Förfallodatum
Förfallodatumet är ogiltigt eller utanför gränserna. Använd formatet "åååå-mm-dd".

Inget förfallodatum satt.

Beroenden

Inga beroenden satta

Referens
bitborg/bitborg-infra!518
Ingen beskrivning angiven.