mirror of
https://github.com/kvcache-ai/AgentENV.git
synced 2026-11-05 01:17:36 +00:00
[GH-ISSUE #211] Add native E2B-compatible persistent volumes #67
Labels
No labels
bug
documentation
enhancement
enhancement
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
kvcache-ai/AgentENV#67
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @yingdi-shan on GitHub (Aug 24, 2026).
Original GitHub issue: https://github.com/kvcache-ai/AgentENV/issues/211
Problem statement
Add first-class persistent volumes with an E2B-compatible control-plane API and sandbox mounting support.
AgentENV currently supports image-backed
attachedDrives, but those drives are coupled to sandbox launch and snapshot state. They do not provide an independent volume identity or lifecycle.The goal is to support the E2B usage pattern:
This issue supersedes #31. Once native volume mounting is supported, #31 can be closed.
Use case
aenvCLI.Current behavior and workarounds
attachedDrivesis primarily supported on the cold-start path./volumesCRUD endpoints.Current workarounds require baking data into templates or using
attachedDrives, which prevents the environment and data from evolving independently.Desired behavior
Implement the E2B-compatible volume endpoints:
POST /volumesGET /volumesGET /volumes/{volumeID}DELETE /volumes/{volumeID}Responses should include E2B-compatible fields such as
volumeIDandname. AgentENV-specific metadata may include volume mode, source, lineage, and reservation state.Support
volumeMountsduring normal and snapshot-backed sandbox creation:Volume modes
roexclusiveThis is the default mode when no mode is specified.
409 Conflict.shared-writeShared-write volumes are not supported. Explicit requests for this mode must be rejected rather than silently emulated.
Creation sources
Support creating a volume from:
Creating from an existing volume must not mutate the source:
rocreates an immutable checkpoint.exclusivecreates an independent copy-on-write child.Direct volume lifecycle operations
Add direct volume-level operations for:
The route names should follow the existing sandbox lifecycle conventions.
CLI
Add, at minimum:
The command should support:
--mode ro|exclusive--from-volume VOLUME_ID--image IMAGE_REFERENCEListing, inspecting, deleting, forking, snapshotting, and restoring volumes should use the same
aenv volumecommand group.Proposed approach
attachedDrivesbehavior for backward compatibility.Compatibility and operational impact
API/config changes:
/volumesendpoints.volumeMountsto sandbox creation and sandbox metadata.aenv volumeCLI commands.Snapshot or storage format changes:
attachedDrivesmust remain readable.New host/runtime requirements:
Upgrade and rollback considerations:
attachedDrivesclients must continue to work.Alternatives considered
attachedDrivesonPOST /sandboxesas proposed in #31.These alternatives either do not provide an independent lifecycle or exceed the guarantees of the current storage architecture.
Non-goals
Volume.readFile()andVolume.writeFile().Pre-submission checklist