Skip to content

feat(providers): add base image support and improve forward compatibility#269

Open
NathanFlurry wants to merge 2 commits intomainfrom
e2b-base-image-support
Open

feat(providers): add base image support and improve forward compatibility#269
NathanFlurry wants to merge 2 commits intomainfrom
e2b-base-image-support

Conversation

@NathanFlurry
Copy link
Member

Summary

Add support for configuring base images across all compute providers while improving forward compatibility of provider SDKs. E2B now accepts an optional template parameter, Modal accepts an optional image parameter, and ComputeSDK's create override now forwards the full SDK options. Fixed a Modal provider bug where encryptedPorts was hardcoded and would overwrite user values.

Changes

  • E2B: Add template parameter to provider options for custom template selection
  • Modal: Add image parameter (string or Image object) for base image configuration, merge additional encrypted ports instead of hardcoding
  • ComputeSDK: Expand create override from minimal interface to full Partial<CreateSandboxOptions> passthrough
  • Daytona: Improve type safety for image option using SDK type reference
  • Docs: Update E2B, Modal, and ComputeSDK deployment guides with base image examples
  • Examples: Add E2B template usage in example code
  • Tests: Add comprehensive lifecycle tests for Modal and ComputeSDK providers with template/image verification

Test Plan

  • TypeScript type-checking passes
  • Provider lifecycle tests added and passing for base image configuration
  • All provider lifecycle tests verify proper passthrough of SDK options

…lity

Add support for configuring base images across all compute providers:
- E2B: Accept optional `template` parameter to select custom templates
- Modal: Accept optional `image` parameter (string or Image object) for base images
- ComputeSDK: Expand `create` override to accept full CreateSandboxOptions payload (image, templateId, etc.)
- Daytona: Improve type safety for `image` option

Improve forward compatibility by making all `create` overrides accept full Partial SDK types, allowing any new provider fields to flow through without code changes. Fix Modal provider bug where `encryptedPorts` was hardcoded and would clobber user-provided values; now merges additional ports instead.

Update docs and examples to demonstrate base image configuration for E2B, Modal, and ComputeSDK. Add comprehensive provider lifecycle tests for Modal and ComputeSDK, including template and image passthrough verification.

Co-Authored-By: Claude Haiku 4.5 <noreply@anthropic.com>
@railway-app
Copy link

railway-app bot commented Mar 17, 2026

🚅 Deployed to the sandbox-agent-pr-269 environment in sandbox-agent

Service Status Web Updated (UTC)
website 😴 Sleeping (View Logs) Web Mar 18, 2026 at 12:01 am
foundry-api ❌ Build Failed (View Logs) Mar 17, 2026 at 11:54 pm
foundry-mock ❌ Build Failed (View Logs) Mar 17, 2026 at 11:54 pm

The `-full` base image already includes sandbox-agent and all agents
pre-installed. Remove redundant apt-get, install script, and
install-agent dockerfile commands from the Modal provider.

Also allow overriding the default image via SANDBOX_AGENT_IMAGE env var
across all providers for testing with different published versions.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant