mirror of
https://github.com/OpenHands/OpenHands.git
synced 2025-12-26 05:48:36 +08:00
Use tini as Docker Runtime Init to Ensure Zombie Processes Get Reaped (#12133)
Co-authored-by: Tim O'Farrell <tofarr@gmail.com>
This commit is contained in:
parent
09af93a02a
commit
94e6490a79
@ -346,6 +346,9 @@ class DockerSandboxService(SandboxService):
|
|||||||
working_dir=sandbox_spec.working_dir,
|
working_dir=sandbox_spec.working_dir,
|
||||||
labels=labels,
|
labels=labels,
|
||||||
detach=True,
|
detach=True,
|
||||||
|
# Use Docker's tini init process to ensure proper signal handling and reaping of
|
||||||
|
# zombie child processes.
|
||||||
|
init=True,
|
||||||
)
|
)
|
||||||
|
|
||||||
sandbox_info = await self._container_to_sandbox_info(container)
|
sandbox_info = await self._container_to_sandbox_info(container)
|
||||||
|
|||||||
@ -520,6 +520,9 @@ class DockerRuntime(ActionExecutionClient):
|
|||||||
|
|
||||||
self.container = self.docker_client.containers.run(
|
self.container = self.docker_client.containers.run(
|
||||||
self.runtime_container_image,
|
self.runtime_container_image,
|
||||||
|
# Use Docker's tini init process to ensure proper signal handling and reaping of
|
||||||
|
# zombie child processes.
|
||||||
|
init=True,
|
||||||
command=command,
|
command=command,
|
||||||
# Override the default 'bash' entrypoint because the command is a binary.
|
# Override the default 'bash' entrypoint because the command is a binary.
|
||||||
entrypoint=[],
|
entrypoint=[],
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user