nixos: runbook for the move, tested restore

Write down the cutover for asxpio-services step by step, with the
times measured in the rehearsal: backup 6 minutes, restore of 29 GB
3 minutes.

The backup script now tolerates files changing under tar in live mode,
which a running Minecraft world always does; in final mode, with the
servers stopped, that remains an error. The restore script can leave
the containers stopped for a restore test.

Also checked on the test server before it was deleted: the production
network layout (interfaces matched by MAC, static IPv6, the private
network on enp7s0) comes up after a reboot with the same routes the
Debian host has.

Assisted-by: Claude:fable-5-2
This commit is contained in:
Sergei Poljanski 2026-11-12 17:13:02 +04:00
commit 7489f6f485
4 changed files with 111 additions and 0 deletions

View file

@ -33,6 +33,12 @@ for name in "${names[@]}"; do
done
rm -f "$sums"
# RESTORE_NO_START=1 leaves everything stopped (restore tests)
if [ -n "${RESTORE_NO_START:-}" ]; then
echo "== data restored; containers left stopped"
exit 0
fi
touch /opt/.restored
echo "== data restored; starting containers"
systemctl start --no-block \