diff --git a/docker/docker-compose.yaml b/docker/docker-compose.yaml index ee60ca7d6..bdd347021 100644 --- a/docker/docker-compose.yaml +++ b/docker/docker-compose.yaml @@ -62,11 +62,12 @@ services: - TZ=Asia/Shanghai # Unified env-override convention: SECTION__SUBSECTION__KEY overrides the # matching config.yaml field (see LoadConfigStage). These map onto - # box.local.* and are forwarded to the Box runtime via INIT RPC. + # box.* and are forwarded to the Box runtime via INIT RPC. - BOX__LOCAL__HOST_ROOT=${LANGBOT_BOX_ROOT:-${PWD}/data/box} - BOX__LOCAL__DEFAULT_WORKSPACE=default - BOX__LOCAL__SKILLS_ROOT=skills - BOX__LOCAL__ALLOWED_MOUNT_ROOTS=${LANGBOT_BOX_ROOT:-${PWD}/data/box} + - BOX__DOCKER__CPU_LIMIT_ENABLED=${LANGBOT_BOX_DOCKER_CPU_LIMIT_ENABLED:-true} ports: - 5300:5300 # For web ui and webhook callback - 2280-2285:2280-2285 # For platform reverse connection diff --git a/src/langbot/templates/config.yaml b/src/langbot/templates/config.yaml index 24874fa6a..2f1c97a7e 100644 --- a/src/langbot/templates/config.yaml +++ b/src/langbot/templates/config.yaml @@ -144,6 +144,8 @@ box: - './data/box' - '/tmp' workspace_quota_mb: null # Optional disk quota override (>= 0). null = profile default. + docker: + cpu_limit_enabled: true # When false, Docker sandbox containers are started without --cpus. Memory and PID limits still apply. e2b: api_key: '' # Can also be set via E2B_API_KEY env var. api_url: '' # Custom API URL for self-hosted deployments.