Commit Graph

2 Commits

Author SHA1 Message Date
457db3934c fix(apt): cache snapshot collision checks
Cache the complete snapshot-name listing once per hook invocation instead\nof querying ZFS separately for every dataset and counter candidate. This\nremoves the repeated full-pool scan that becomes expensive when recursive\nsnapshot histories are large.\n\nCache the operation suffix as well and return an explicit success status\nfrom snapshot-name generation so collision retries are unambiguous. Ignore\nAPT configuration-only records because they do not represent package data\nchanges requiring a new pre-install snapshot.
2026-09-16 09:46:01 +02:00
942128c89f feat(apt): add package-aware snapshot helper
Parse the APT package action protocol and classify records by operation.
Use the package list to determine important and trivial snapshot chains,
then generate collision-resistant names containing shortened package data.

Select ZFS datasets through the configured property or explicit roots.
Create recursive snapshots atomically, support dry-run output, and prune
old snapshots from the matching retention chain after success.

Preserve the original warning-oriented behavior by reporting snapshot and
retention failures without aborting the package operation.
2026-09-16 09:05:17 +02:00