GeezerVison is showing adk.dev — ContainerCodeExecutorOptions | ADK for TypeScript: API Reference - v2.5.0
- ContainerCodeExecutorOptions
Interface ContainerCodeExecutorOptions
Properties
OptionalbaseUrl
baseUrl?: string
Optional base url of a user-hosted Docker daemon (e.g. tcp://host:2375).
Optionaldocker
docker?: Dockerode
Injected Docker client, primarily for testing so unit tests never touch a
real Docker daemon. Defaults to a new client built from baseUrl.
OptionaldockerPath
dockerPath?: string
Path to a directory containing a Dockerfile. If set, the image is built
from it instead of using a prebuilt tag. Either image or dockerPath
must be set.
Optionalimage
image?: string
Tag of the predefined or custom image to run on the container. Either
image or dockerPath must be set. Defaults to adk-code-executor:latest
when only dockerPath is given.
OptionalmaxContainers
maxContainers?: number
Maximum number of session containers to keep running concurrently.
When exceeded, the least recently used idle session container is stopped
and evicted. A container that is running code is never evicted, so the
count can exceed the limit until that run ends. Must be a positive
integer.
OptionalnetworkEnabled
networkEnabled?: boolean
Start the container with networking enabled. Defaults to false so
untrusted, model-generated code cannot reach the network (the cloud
metadata endpoint, internal services, or exfiltration destinations).
OptionaltimeoutSeconds
timeoutSeconds?: number
Wall-clock timeout in seconds for a single execution. Must be greater than
0; defaults to 300. Each session runs in its own long-lived container, so
an unbounded run (e.g. a loop emitted by the model) would burn that
container's CPU for every later call in the same session. Raise it rather
than remove it for a computation that legitimately runs longer.