Remove the git clone container's anonymous volume with it (closes #215) #217

Merged
clawbot merged 2 commits from issue-215-clone-volume into next2 2026-09-23 12:04:32 +02:00
2 Commits
Author SHA1 Message Date
sneak 3e64d6f087 Remove the clone container even when the deploy is cancelled (closes #215)
Check / check (pull_request) Skipped
The deferred removal used the deploy context, so a cancelled deploy
(a newer push, or the build timeout) never sent the remove request and
left the clone container and its volume behind. It now uses
context.WithoutCancel, and the test gains a case that cancels the
context while the clone is running.

Model: opus-5-5
2026-09-23 09:45:07 +00:00
sneak a44d4a2647 Remove the git clone container's anonymous volume with it (closes #215)
The pinned alpine/git image declares a volume at /git, so Docker gives
every clone container an anonymous volume. The container was removed
without its volumes, leaving one volume behind per deploy. The removal
now also removes the container's anonymous volumes, on success and on
failure. A test runs a clone against a fake Docker API and checks the
removal asks for volumes to be removed.

Model: opus-5-5
2026-09-23 09:45:07 +00:00