{"id":51136173,"url":"https://github.com/contember/edvabe","last_synced_at":"2026-06-25T18:01:46.989Z","repository":{"id":351544977,"uuid":"1211439681","full_name":"contember/edvabe","owner":"contember","description":"Local E2B-compatible sandbox runtime — a single Go binary that exposes an E2B-compatible API on localhost, backed by Docker containers","archived":false,"fork":false,"pushed_at":"2026-04-24T15:01:41.000Z","size":404,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-04-24T17:05:09.312Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/contember.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2026-04-15T11:52:04.000Z","updated_at":"2026-04-24T15:01:42.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/contember/edvabe","commit_stats":null,"previous_names":["contember/edvabe"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/contember/edvabe","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/contember%2Fedvabe","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/contember%2Fedvabe/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/contember%2Fedvabe/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/contember%2Fedvabe/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/contember","download_url":"https://codeload.github.com/contember/edvabe/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/contember%2Fedvabe/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":34786238,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-06-25T02:00:05.521Z","response_time":101,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2026-06-25T18:01:45.676Z","updated_at":"2026-06-25T18:01:46.984Z","avatar_url":"https://github.com/contember.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# edvabe\n\nLocal [E2B](https://e2b.dev)-compatible sandbox runtime. A single Go\nbinary that exposes a wire-compatible subset of the E2B cloud sandbox\nAPI on a developer's laptop: point an unmodified E2B SDK at it via env\nvars and sandboxes run in local Docker containers instead of E2B's\ncloud.\n\n## Features\n\n- **Drop-in compatible** with unmodified E2B Python and TypeScript SDKs\n- **Single binary** — no Redis, Postgres, Nomad, or Firecracker\n- **Cross-platform** — Linux and macOS (x86_64 + arm64)\n- **Sandbox lifecycle** — create, kill, pause, resume, snapshots\n- **Custom templates** — programmatic `Template.build()` from the SDK\n- **Code interpreter** — `@e2b/code-interpreter` SDK works out of the box\n- **Full API surface** — teams, volumes, api-keys stubs so the SDK never crashes\n\n## Quick start\n\n### Option A: Go install\n\n```sh\ngo install github.com/contember/edvabe/cmd/edvabe@latest\n\nedvabe doctor        # preflight check\nedvabe build-image   # first-time: build edvabe/base:latest (~60s)\nedvabe serve         # listens on :3000\n```\n\n### Option B: Docker (recommended for docker-compose setups)\n\n```sh\ndocker run --rm \\\n  -p 3000:3000 \\\n  -v /var/run/docker.sock:/var/run/docker.sock \\\n  -v edvabe-data:/data \\\n  ghcr.io/contember/edvabe:main serve\n```\n\n### Docker Compose\n\n```yaml\nservices:\n  edvabe:\n    image: ghcr.io/contember/edvabe:main\n    ports:\n      - \"3000:3000\"\n    volumes:\n      - /var/run/docker.sock:/var/run/docker.sock\n      - edvabe-data:/data\n    environment:\n      EDVABE_STATE_DIR: /data\n      EDVABE_CACHE_DIR: /data/cache\n\nvolumes:\n  edvabe-data:\n```\n\nThe Docker socket mount is required — edvabe creates sandbox containers\nas siblings on the host Docker daemon.\n\n## Point an SDK at it\n\nSet these env vars in the process running your E2B SDK code:\n\n```sh\nexport E2B_API_URL=http://localhost:3000\nexport E2B_DOMAIN=localhost:3000\nexport E2B_API_KEY=edvabe_local\nexport E2B_SANDBOX_URL=http://localhost:3000\n```\n\nWhen running inside docker-compose, replace `localhost:3000` with\n`edvabe:3000` (the service name).\n\nThen unmodified SDK code works:\n\n```python\nfrom e2b import Sandbox\n\nsbx = Sandbox.create(timeout=60)\nresult = sbx.commands.run(\"echo hello from edvabe\")\nprint(result.stdout)  # \"hello from edvabe\\n\"\nsbx.kill()\n```\n\n### Code interpreter\n\n```sh\nedvabe build-image --template=code-interpreter   # ~10 min first time\n```\n\n```python\nfrom e2b_code_interpreter import Sandbox\n\nsbx = Sandbox()\nexecution = sbx.run_code(\"1 + 1\")\nprint(execution.results[0].text)  # \"2\"\nsbx.kill()\n```\n\n### Custom templates\n\nThe SDK's programmatic `Template.build()` works against edvabe — it\ntranslates step arrays into Dockerfiles and builds them locally:\n\n```typescript\nimport { Template, Sandbox } from 'e2b'\n\nconst tpl = Template()\n  .fromImage('oven/bun:slim')\n  .aptInstall(['curl', 'git'])\n  .runCmd('echo \"built\" \u003e /etc/marker')\n\nawait Template.build(tpl, { alias: 'my-template' })\nconst sbx = await Sandbox.create('my-template')\n```\n\n## Commands\n\n```sh\nedvabe serve [--port 3000]                          # start server\nedvabe doctor [--port 3000]                         # preflight checks\nedvabe build-image [--template=base|code-interpreter|all]  # build images\nedvabe pull-base                                    # pull upstream e2bdev/base\nedvabe version                                      # print version\n```\n\n## Environment variables\n\n| Variable | Default | Description |\n|---|---|---|\n| `EDVABE_STATE_DIR` | `~/.local/share/edvabe` | Template store (templates.json) |\n| `EDVABE_CACHE_DIR` | `~/.cache/edvabe/template-files` | File context cache |\n| `EDVABE_BUILD_DIR` | `~/.cache/edvabe/builds` | Build scratch directory |\n| `DOCKER_HOST` | auto-detected | Docker socket path |\n\n## Test\n\n```sh\nmake test                             # go test ./...\nmake test-e2e-python                  # Python SDK E2E (create, commands, files, pty, watch)\nmake test-e2e-ts                      # TypeScript SDK E2E\nmake test-e2e-code-interpreter-python # code interpreter Python E2E\nmake test-e2e-code-interpreter-ts     # code interpreter TypeScript E2E\n```\n\n## Architecture\n\nedvabe implements the E2B **control plane** in Go — sandbox CRUD,\ntemplate builds, pause/resume, and all the stub endpoints the SDK\nexpects. The **data plane** (filesystem, process, PTY, watchers) is\nhandled by upstream [envd](https://github.com/e2b-dev/infra/tree/main/packages/envd)\nrunning inside each sandbox container. edvabe reverse-proxies SDK\nrequests to envd, giving byte-exact wire compatibility without\nreimplementing the ~6000 LOC envd protocol.\n\n```\nSDK ──HTTP──\u003e edvabe (:3000)\n                │\n                ├─ control plane (Go)\n                │    sandboxes, templates, teams, volumes, ...\n                │\n                └─ reverse proxy ──\u003e Docker container\n                     │                  │\n                     │                  ├─ envd (:49983)\n                     │                  │    files, process, PTY, watch\n                     │                  │\n                     │                  └─ code-interpreter (:49999)\n                     │                       Jupyter + FastAPI overlay\n                     │\n                     └─ routed by E2b-Sandbox-Id + E2b-Sandbox-Port headers\n```\n\n**Key design decisions:**\n\n- **Templates are Docker images.** `Template.build()` translates SDK\n  step arrays into generated Dockerfiles and runs `docker build`.\n- **envd is injected** into every user template via a `COPY --from`\n  stage — user images don't need to know about envd.\n- **Pause = `docker pause`**, snapshot = `docker commit`. No live\n  memory snapshots. Documented trade-off for a local dev tool.\n- **Runtime and Agent are pluggable interfaces** behind\n  `internal/runtime/` and `internal/agent/`. Docker is the v1 backend;\n  Firecracker/libkrun could slot in later.\n\nSee [docs/05-architecture.md](docs/05-architecture.md) for the full\ndesign and [docs/03-api-surface.md](docs/03-api-surface.md) for the\nwire protocol.\n\n## License\n\n[MIT](LICENSE) — Contember Limited\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcontember%2Fedvabe","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcontember%2Fedvabe","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcontember%2Fedvabe/lists"}