GNOME Bugzilla – Bug 743882
size-based pruning
Last modified: 2018-08-17 18:59:38 UTC
Not every system admin will want to keep binary history forever; right now the easy option is only: - Create a new repo, commit to it, archive (or delete) the old one, and swap new one into place We should support a "rolling" prune, like what backup systems support. For example: ostree --repo=repo prune myos/x86_64/blah --refs-only --rolling-upto=20G" or so, where we delete older commits more aggressively.
This might just be my email caching experience talking, but to me "rolling" implies an invariant that's maintained automatically in the background, like a clean up action after an "ostree pull". Would it make sense to support a max-history-size option for remotes, or would you prefer to keep the pruning explicit?
(I guess it would be an option for repos, not remotes - but you get what I mean.)
Pruning remotes is a related story, but for this bug I was thinking from the perspective of a repository owner.
At the moment we don't have a convenient command line way to prune the history of just one branch. Further, we should have some sort of "tombstone" replacement for a commit when history is truncated. This would allow mirrors to know the parent isn't available, and to stop rather than erroring out.
See also https://github.com/projectatomic/rpm-ostree-toolbox/commit/8ffdbb683cec93c983d88d499cbfc042c30639de
We could choose to have some of this functionality in https://github.com/cgwalters/ostree-scripts/ too.
(In reply to Colin Walters from comment #4) > Further, we should have some sort of "tombstone" replacement for a commit > when history is truncated. This would allow mirrors to know the parent > isn't available, and to stop rather than erroring out. This reminded me of the End-of-Life notifications: https://github.com/projectatomic/rpm-ostree/issues/142 Though this is kind of the reverse case, could it use a similar mechanism? Embed some detached metadata in the commit whose parent got pruned ("parent-pruned")?
Tombstone commits landed. We don't have any size-based pruning though which would still be nice.
OSTree has moved to Github a while ago. Furthermore, GNOME Bugzilla will be shut down and replaced by gitlab.gnome.org. If the problem reported in this Bugzilla ticket is still valid, please report it to https://github.com/ostreedev/ostree/issues instead. Thank you! Closing this report as WONTFIX as part of Bugzilla Housekeeping.