feat: persistent volumes with TTL for container/worktree storage (archie-core-j7v)

Add [containers].volume_ttl (default 72h). Persistent-storage repos get a
per-repo bare Git cache (--reference-if-able --dissociate) so task
worktrees clone fast without repeated full network clones, while staying
fully independent of the cache's lifecycle — cache expiry can never
corrupt an active or parked task's worktree. Docker repo volumes are
labeled as Archie-owned and swept non-forced (a volume still attached to a
running container survives and retries next cycle); the repo cache
directory is swept by mtime. Both cleanups run at daemon startup and each
poll cycle.

Filed archie-core-756 (repo-wide golangci-lint baseline) and archie-core-340
(intermittent JetStream TempDir teardown flake) as separate follow-ups
rather than scope-creeping them into this change.
This commit is contained in:
sam committed 2026-07-24 10:22:11 +10:00
1 parent 827c108401
commit e4368f70af
15 files changed
+562 -29

No files matched your search

+6
View File
@@ -68,21 +68,27 @@ func (f *prCapturingForge) AcceptInvitations(context.Context) error
func (f *prCapturingForge) AssignedIssues(context.Context, string, string, string) ([]forge.Issue, error) {
panic("unexpected call")
}
func (f *prCapturingForge) IssuesWithLabel(context.Context, string, string, string) ([]forge.Issue, error) {
panic("unexpected call")
}
func (f *prCapturingForge) RepliesAfter(context.Context, string, string, int, int64, string) ([]forge.Reply, error) {
panic("unexpected call")
}
func (f *prCapturingForge) PRState(context.Context, string, string, int) (string, error) {
panic("unexpected call")
}
func (f *prCapturingForge) CreateIssue(context.Context, string, string, string, string, []string) (int, error) {
panic("unexpected call")
}
func (f *prCapturingForge) React(context.Context, string, string, int, string) error {
panic("unexpected call")
}
func (f *prCapturingForge) VerifyPush(context.Context, string, string) error {
panic("unexpected call")
}
+4
View File
@@ -35,15 +35,19 @@ func (stubForge) AcceptInvitations(context.Context) error
func (stubForge) AssignedIssues(context.Context, string, string, string) ([]forge.Issue, error) {
panic("unexpected call")
}
func (stubForge) IssuesWithLabel(context.Context, string, string, string) ([]forge.Issue, error) {
panic("unexpected call")
}
func (stubForge) RepliesAfter(context.Context, string, string, int, int64, string) ([]forge.Reply, error) {
panic("unexpected call")
}
func (stubForge) PRState(context.Context, string, string, int) (string, error) {
panic("unexpected call")
}
func (stubForge) CreateIssue(context.Context, string, string, string, string, []string) (int, error) {
panic("unexpected call")
}