Closed vito closed 1 year ago
Thanks for the report, I will take a look. Theoretically, the change was to send the sigkill to the process managed by runc (the pid1 in the container), not to runc itself. Clearly something is not matching my expectations.
After bumping Dagger to Buildkit v0.11.5 we noticed service containers stay running rather than stopping after we interrupt them.
We tracked it down https://github.com/moby/buildkit/pull/3722 and confirmed reverting it fixes the issue.
Here's a test (for
client/client_test.go
) that will pass in v0.11.4 but fail in v0.11.5. It runs a container that sleeps and writes to a cache, interrupts it before the sleep finishes, waits for longer than the sleep, and then checks that the file doesn't exist in the cache.There's probably a better way to actually test this, the above was just the first idea that popped into my head; it'd make for a very slow test.
I haven't looked too deeply at the original PR, but I did notice that it seems to switch from running
runc kill <id>
to sendingSIGKILL
to the runc process, which seems semantically different, but maybe that's the idea.cc @coryb @tonistiigi @sipsma