infra/stacks/nextcloud
Viktor Barzin 3d28870e25 nextcloud: fix backup retention to sort by name, not mtime
The dated backup dirs are named YYYYMMDD_HHMMSS, but the cleanup used
`ls -dt` (mtime). `rsync -a` stamps the backup dir with the SOURCE dir's
mtime, so the freshest backup didn't sort as newest — the retention step
deleted the new backup and kept a stale one. Sort lexically (chronological
for these names) and keep the last.

Also exclude html/ (the app code, reproducible from the now-pinned image;
the real config lives at config/config.php, html/config is empty) so the
backup is config+data+custom_apps only → ~4.3G (<5G target).

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-06-01 15:15:26 +00:00
..
.terraform.lock.hcl Woodpecker CI deploy [CI SKIP] 2026-05-27 18:38:09 +00:00
backend.tf Woodpecker CI deploy [CI SKIP] 2026-06-01 15:15:26 +00:00
chart_values.yaml backup: stop offsite-copying regenerable data; shrink nextcloud backup; pin nextcloud image 2026-06-01 15:15:26 +00:00
external_storage.tf nextcloud(external_storage): add per-mount enableSharing option 2026-05-24 11:39:16 +00:00
main.tf nextcloud: fix backup retention to sort by name, not mtime 2026-06-01 15:15:26 +00:00
providers.tf Woodpecker CI deploy [CI SKIP] 2026-05-27 18:38:09 +00:00
secrets [ci skip] Move Terraform modules into stack directories 2026-02-22 14:38:14 +00:00
terragrunt.hcl migrate all secrets from SOPS to Vault KV 2026-03-14 17:15:48 +00:00