feat(tools): implement ContainerToolRunner for Docker/Podman isolated tool execution #5526

Open
opened 2026-04-09 07:13:08 +00:00 by HAL9000 · 0 comments
Owner

Background

Part of Epic #5504 (Container Tool Execution). Implements the ContainerToolRunner that executes tools inside Docker or Podman containers, providing isolation and reproducibility for tool execution.

Expected Behavior

  • ContainerToolRunner class that wraps tool execution in Docker/Podman containers
  • Container configuration in tool YAML: container.image, container.volumes, container.env, container.runtime (docker/podman)
  • Automatic image pulling if not present locally
  • Container lifecycle: create → run → capture output → cleanup
  • Integration with existing ToolRunner dispatch chain via tool_type: container
  • Timeout enforcement for container execution

Subtasks

  • Implement ContainerConfig model for tool YAML container configuration
  • Implement ContainerToolRunner with Docker SDK integration
  • Add Podman support via container.runtime: podman config
  • Implement container lifecycle management (pull, create, run, cleanup)
  • Wire ContainerToolRunner into ToolRunner dispatch chain for tool_type: container
  • Write Behave unit tests for ContainerToolRunner

Definition of Done

  • ContainerToolRunner executes tools in Docker containers
  • Container configuration works via tool YAML
  • Container lifecycle managed correctly (no leaks)
  • Timeout enforcement works
  • All nox stages pass
  • Coverage >= 97%

Metadata


Automated by CleverAgents Bot
Supervisor: Epic Planning | Agent: epic-planner

## Background Part of Epic #5504 (Container Tool Execution). Implements the `ContainerToolRunner` that executes tools inside Docker or Podman containers, providing isolation and reproducibility for tool execution. ## Expected Behavior - `ContainerToolRunner` class that wraps tool execution in Docker/Podman containers - Container configuration in tool YAML: `container.image`, `container.volumes`, `container.env`, `container.runtime` (docker/podman) - Automatic image pulling if not present locally - Container lifecycle: create → run → capture output → cleanup - Integration with existing `ToolRunner` dispatch chain via `tool_type: container` - Timeout enforcement for container execution ## Subtasks - [ ] Implement `ContainerConfig` model for tool YAML container configuration - [ ] Implement `ContainerToolRunner` with Docker SDK integration - [ ] Add Podman support via `container.runtime: podman` config - [ ] Implement container lifecycle management (pull, create, run, cleanup) - [ ] Wire `ContainerToolRunner` into `ToolRunner` dispatch chain for `tool_type: container` - [ ] Write Behave unit tests for ContainerToolRunner ## Definition of Done - [ ] `ContainerToolRunner` executes tools in Docker containers - [ ] Container configuration works via tool YAML - [ ] Container lifecycle managed correctly (no leaks) - [ ] Timeout enforcement works - [ ] All nox stages pass - [ ] Coverage >= 97% ## Metadata - **Branch**: `feat/v3.6.0/container-tool-execution` - **Commit Message**: `feat(tools): implement ContainerToolRunner for Docker/Podman isolated tool execution` - **Milestone**: v3.6.0 - **Parent Epic**: #5504 --- **Automated by CleverAgents Bot** Supervisor: Epic Planning | Agent: epic-planner
HAL9000 added this to the v3.6.0 milestone 2026-04-09 07:15:34 +00:00
HAL9000 added the
Priority
High
State
Verified
Type
Feature
labels 2026-04-09 07:20:41 +00:00
HAL9000 added
Priority
Medium
State
Unverified
and removed
Priority
High
State
Verified
labels 2026-04-09 07:25:33 +00:00
HAL9000 added
State
Verified
and removed
State
Unverified
labels 2026-04-09 07:38:38 +00:00
HAL9000 added the
Points
8
label 2026-04-09 07:42:09 +00:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Reference: cleveragents/cleveragents-core#5526