fix(build): clear a killed boot test's container and volume first
Validate game templates / validate (push) Successful in 20s
Validate game templates / boot-test (push) Skipped
Validate game templates / publish (push) Skipped

When the worker is restarted mid-build (watchtower updating its image), the
boot test's container and volume are left behind, and the next boot test of
that game deploys under the same name. Remove them before each boot test.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
gregandClaude Opus 5.5 committed 2026-10-25 18:32:43 -04:00
1 parent ea2c0b1eeb
commit e9e78610d6
1 file changed
+4
+4
View File
@@ -236,6 +236,10 @@ func bootCheck(gamesDir, id, agentImage string, wantOutside bool) (problems, ver
if err != nil { if err != nil {
return nil, nil, err return nil, nil, err
} }
// A boot test that was killed (worker restarted mid-build) leaves its container and volume behind,
// and the next deploy under the same name would trip over them
runCmd("docker", "rm", "-f", "boottest-"+id)
runCmd("docker", "volume", "rm", "-f", "boottest-"+id+"-data")
payloadCmd := exec.Command(self, "boottest-payload", "-games", gamesDir, id) payloadCmd := exec.Command(self, "boottest-payload", "-games", gamesDir, id)
var stderr bytes.Buffer var stderr bytes.Buffer
payloadCmd.Stderr = &stderr payloadCmd.Stderr = &stderr