add sandbox runtime control endpoints
This commit is contained in:
parent
0ca0bac9bf
commit
1b38bcfeab
17 changed files with 1408 additions and 119 deletions
|
|
@ -247,6 +247,20 @@ def _load_sandbox_config(
|
|||
env,
|
||||
'APP_SANDBOX_IMAGE',
|
||||
),
|
||||
network_name=_yaml_or_env_str(
|
||||
section,
|
||||
'network_name',
|
||||
'sandbox.network_name',
|
||||
env,
|
||||
'APP_SANDBOX_NETWORK_NAME',
|
||||
),
|
||||
agent_service_port=_yaml_or_env_int(
|
||||
section,
|
||||
'agent_service_port',
|
||||
'sandbox.agent_service_port',
|
||||
env,
|
||||
'APP_SANDBOX_AGENT_SERVICE_PORT',
|
||||
),
|
||||
ttl_seconds=_yaml_or_env_int(
|
||||
section,
|
||||
'ttl_seconds',
|
||||
|
|
@ -303,6 +317,13 @@ def _load_sandbox_config(
|
|||
env,
|
||||
'APP_SANDBOX_LAMBDA_TOOLS_MOUNT_PATH',
|
||||
),
|
||||
volume_mount_path=_yaml_or_env_str(
|
||||
section,
|
||||
'volume_mount_path',
|
||||
'sandbox.volume_mount_path',
|
||||
env,
|
||||
'APP_SANDBOX_VOLUME_MOUNT_PATH',
|
||||
),
|
||||
)
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -48,6 +48,8 @@ class DockerConfig:
|
|||
@dataclass(frozen=True, slots=True)
|
||||
class SandboxConfig:
|
||||
image: str
|
||||
network_name: str
|
||||
agent_service_port: int
|
||||
ttl_seconds: int
|
||||
cleanup_interval_seconds: int
|
||||
chats_root: str
|
||||
|
|
@ -56,6 +58,7 @@ class SandboxConfig:
|
|||
chat_mount_path: str
|
||||
dependencies_mount_path: str
|
||||
lambda_tools_mount_path: str
|
||||
volume_mount_path: str
|
||||
|
||||
|
||||
@dataclass(frozen=True, slots=True)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue