fix(backup) + chore: upgrade to 1.3.0+6.42.0-alpine #1

Merged
notplants merged 1 commits from ci/mysql-backup into main 2026-06-02 17:41:01 +00:00

Adds a single-file mysqldump backup + reimport-on-restore hook (mysql_backup.sh). The published recipe dumps via mysqldump --tab but ships no restore hook, so restore was a silent no-op (data loss). Same fix class as the postgres recipes. Caught by cc-ci P4 data-integrity test.

Adds a single-file mysqldump backup + reimport-on-restore hook (mysql_backup.sh). The published recipe dumps via mysqldump --tab but ships no restore hook, so restore was a silent no-op (data loss). Same fix class as the postgres recipes. Caught by cc-ci P4 data-integrity test.
autonomic-bot added 1 commit 2026-05-30 04:59:07 +00:00
The previous recipe backed the DB up as a mysqldump --tab into /var/lib/mysql-files with NO restore
hook (and the mysql data volume itself was not backupbot-labelled), so a restored backup silently
kept the live, un-restored DB state — data loss on restore. Add mysql_backup.sh (backup: gzipped
mysqldump --databases ghost into the data volume; restore: reimport it) wired via backupbot
backup.pre-hook + restore.post-hook, mirroring the postgres recipes (mattermost-lts, immich). Bump
1.2.0 -> 1.3.0.
autonomic-bot added 1 commit 2026-05-30 05:42:03 +00:00
backupbot restores backed-up files by volume; an absolute backup.path is not mapped back into the
volume on restore, so the restore.post-hook reimported a missing dump. Use
backupbot.backup.volumes.mysql.path=backup.sql.gz (mirrors the postgres recipes).
autonomic-bot added 1 commit 2026-05-30 16:18:16 +00:00
Ghost's fresh-DB first boot runs a full schema migration (dozens of CREATE
TABLEs, each a separate MySQL round-trip; ~6-9min on a small/slow node). The
1m start_period + 10x30s retries (~6min grace) is too tight there: swarm marks
the still-migrating task unhealthy and kills it mid-migration, leaving a stale
migrations_lock row so every later task deadlocks (MigrationsAreLockedError).

start_period only widens the startup grace window: a healthy check still marks
the task healthy immediately, so fast hosts are unaffected. It cannot be exposed
as an env var (abra validates the literal compose 'duration' format BEFORE env
substitution, rejecting ${VAR} / "${VAR:-1m}" with FATA 'Does not match format
duration'), so a literal bump is the only way to widen it.
Author
Owner

Auto-closed by /recipe-upgrade: superseded by upgrade-1.3.0+6.42.0-alpine (fresh upgrade against current upstream main)

Auto-closed by /recipe-upgrade: superseded by upgrade-1.3.0+6.42.0-alpine (fresh upgrade against current upstream main)
autonomic-bot closed this pull request 2026-06-01 13:30:56 +00:00
autonomic-bot reopened this pull request 2026-06-02 00:07:50 +00:00
Author
Owner

Reopened. This PR was auto-closed in error by the old /recipe-upgrade superseded behavior when upgrade PR #2 was opened — but it's unrelated to that upgrade: it's a real backup/restore data-loss fix (restore was a silent no-op). That auto-close-superseded behavior has now been removed, so unrelated open PRs stay open. @notplants please review.

Reopened. This PR was auto-closed in error by the old `/recipe-upgrade` *superseded* behavior when upgrade PR #2 was opened — but it's unrelated to that upgrade: it's a real backup/restore data-loss fix (restore was a silent no-op). That auto-close-superseded behavior has now been removed, so unrelated open PRs stay open. @notplants please review.
autonomic-bot added 1 commit 2026-06-02 02:05:03 +00:00
chore: upgrade to 1.3.0+6.42.0-alpine
All checks were successful
cc-ci/testme cc-ci: success
fefff0d643
autonomic-bot changed title from fix(backup): reimport mysqldump on restore (restore was a no-op) to fix(backup) + chore: upgrade to 1.3.0+6.42.0-alpine 2026-06-02 02:05:09 +00:00
Author
Owner

!testme

!testme
Author
Owner

🌻 cc-cighost @ 26ef5e66 passed

cc-ci result card

level

full logs · dashboard

<!-- cc-ci:testme --> 🌻 **cc-ci** — `ghost` @ `26ef5e66` ✅ **passed** [![cc-ci result card](https://ci.commoninternet.net/runs/174/summary.png)](https://drone.ci.commoninternet.net/recipe-maintainers/cc-ci/174) [![level](https://ci.commoninternet.net/runs/174/badge.svg)](https://drone.ci.commoninternet.net/recipe-maintainers/cc-ci/174) [full logs](https://drone.ci.commoninternet.net/recipe-maintainers/cc-ci/174) · [dashboard](https://ci.commoninternet.net/)
autonomic-bot added 1 commit 2026-06-02 17:04:08 +00:00
refactor(backup): inline backupbot hooks, drop mysql_backup.sh
All checks were successful
cc-ci/testme cc-ci: success
26ef5e6625
Move the mysqldump/gunzip commands directly into the
backupbot.backup.pre-hook / backupbot.restore.post-hook label values
on the db service and delete the external mysql_backup.sh + its
config mount + MYSQL_BACKUP_VERSION. Matches the inline pattern used
by akaunting / engelsystem / forgejo and removes one file from the
recipe surface area.
Owner

!testme

!testme
autonomic-bot force-pushed ci/mysql-backup from 26ef5e6625 to 11bac13e30 2026-06-02 17:29:57 +00:00 Compare
Owner

!testme

!testme
Author
Owner

🌻 cc-cighost @ 11bac13e passed

cc-ci result card

level

full logs · dashboard

<!-- cc-ci:testme --> 🌻 **cc-ci** — `ghost` @ `11bac13e` ✅ **passed** [![cc-ci result card](https://ci.commoninternet.net/runs/176/summary.png)](https://drone.ci.commoninternet.net/recipe-maintainers/cc-ci/176) [![level](https://ci.commoninternet.net/runs/176/badge.svg)](https://drone.ci.commoninternet.net/recipe-maintainers/cc-ci/176) [full logs](https://drone.ci.commoninternet.net/recipe-maintainers/cc-ci/176) · [dashboard](https://ci.commoninternet.net/)
notplants merged commit 0c1f32e458 into main 2026-06-02 17:41:01 +00:00
notplants deleted branch ci/mysql-backup 2026-06-02 17:41:02 +00:00
Sign in to join this conversation.
No Reviewers
No Label
2 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: recipe-maintainers/ghost#1
No description provided.