feat(restic): automate appdata restores#261
Merged
Merged
Conversation
Add an Ansible-native restore flow so DR and single-app restores can use the shared restic repo without hand-built kubectl sequences. The role plans from live Argo CD/PVC state by default, requires explicit confirmation before destructive work, and preserves the NFS xattr restore guardrail.
Keep the PR focused on the implemented restore role and runbook. The standalone implementation plan was useful while building the feature, but it should not live as permanent docs now that the Ansible workflow is implemented.
Keep the restore docs focused on the implemented Ansible workflow: preview, confirmed restore, full DR, and fallback constraints. The single-PVC flow is now described as the app restore it actually is, which removes duplicate procedure text.
Use a general restic role name so future restic operations can live under one Ansible role. Restore-specific variables keep their existing prefix because they describe this role entrypoint's current behavior.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
task restic:restoreandtask restic:restore-allwrappers for plan-only or confirmed Kubernetes appdata restores from the shared restic repo.restic_restorerole that infers target PVCs from live Argo CD Application resources and live PVCs, defaults snapshots tolatest, and includes Argo-managednfs-fastappdata by default for full restores./restore/data/appdata/..., restore with--exclude-xattr '*', then resume workloads and sync policy.Test Plan
./.venv/bin/ansible-playbook ansible/tests/restic-restore.ymltask fmttask lintgit diff --checktask restic:restore app=paperlesstask restic:restore-allNotes
confirm_restore=trueis passed.nfs-fastPVCs, while excluding shared/static storage such asmedia,restic-repo, andrestic-appdata.