{"id":51140676,"url":"https://github.com/ariana-dot-dev/harbor-box","last_synced_at":"2026-06-25T22:30:29.558Z","repository":{"id":365597644,"uuid":"1272852862","full_name":"ariana-dot-dev/harbor-box","owner":"ariana-dot-dev","description":"Harbor environment adapter backed by the Ascii Box public API","archived":false,"fork":false,"pushed_at":"2026-06-18T03:04:55.000Z","size":59,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-06-18T04:18:38.072Z","etag":null,"topics":["ai-agents","ascii-box","harbor","sandbox"],"latest_commit_sha":null,"homepage":null,"language":"Python","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/ariana-dot-dev.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","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-06-18T01:54:23.000Z","updated_at":"2026-06-18T03:00:23.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/ariana-dot-dev/harbor-box","commit_stats":null,"previous_names":["ariana-dot-dev/harbor-box"],"tags_count":3,"template":false,"template_full_name":null,"purl":"pkg:github/ariana-dot-dev/harbor-box","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ariana-dot-dev%2Fharbor-box","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ariana-dot-dev%2Fharbor-box/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ariana-dot-dev%2Fharbor-box/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ariana-dot-dev%2Fharbor-box/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ariana-dot-dev","download_url":"https://codeload.github.com/ariana-dot-dev/harbor-box/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ariana-dot-dev%2Fharbor-box/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":34795436,"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":["ai-agents","ascii-box","harbor","sandbox"],"created_at":"2026-06-25T22:30:28.902Z","updated_at":"2026-06-25T22:30:29.553Z","avatar_url":"https://github.com/ariana-dot-dev.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# harbor-box\n\n[![CI](https://github.com/ariana-dot-dev/harbor-box/actions/workflows/ci.yml/badge.svg)](https://github.com/ariana-dot-dev/harbor-box/actions/workflows/ci.yml)\n\nA [Harbor](https://pypi.org/project/harbor/) environment adapter backed by the\n**[Ascii Box](https://box.ascii.dev)** public API.\n\n`BoxEnvironment` runs Harbor agent trials and evals inside an Ascii Box instead\nof a local Docker container, E2B, or Modal. It implements Harbor's\n`BaseEnvironment` surface — lifecycle, command execution, environment variables,\nand file/dir upload + download — on top of Box's public HTTP API.\n\nSome Harbor features aren't available on Box today: network policies, Docker\nimage builds / Compose, and GPUs / TPUs / Windows.\n\n## Layout\n\n| Path | What |\n| --- | --- |\n| `sdks/harbor_box_environment.py` | `BoxEnvironment` — the Harbor adapter plus a small async Box API client |\n| `sdks/harbor-box-evals/` | End-to-end evals: a from-scratch Claude Agent SDK coding agent solving tasks inside a Box |\n\n## Install\n\n```bash\npip install harbor-box                 # imports as: harbor_box_environment\n```\n\nOr from a clone of this repo:\n\n```bash\npip install -r requirements.txt        # harbor\u003e=0.14.0, httpx, tenacity\n```\n\n## Configure\n\n```bash\ncp .env.example .env\n# fill in BOX_API_KEY\n```\n\n`BOX_API_KEY` is required — get one at \u003chttps://box.ascii.dev\u003e. Your `.env` is\ngitignored; never commit secrets.\n\n## Use it with Harbor\n\n```bash\nexport BOX_API_KEY=...\nharbor task run path/to/task.yaml \\\n  --environment-import-path harbor_box_environment:BoxEnvironment\n```\n\n## Preparing the environment\n\nBox runs a ready Ubuntu image — it doesn't build Docker images. The adapter\nprepares each box from your Harbor environment directory instead:\n\n- **Files** in the environment directory are uploaded into the box's working\n  directory at start, so fixtures, configs, and scripts are in place before the\n  agent runs.\n- The **`Dockerfile`** is read only for its `WORKDIR`; build steps\n  (`RUN` / `COPY` / …) are not executed. Install dependencies from a setup\n  command (`await env.exec(...)`) or your agent, not the image.\n- **Environment variables** come from the Harbor environment config and are\n  forwarded into the box; per-command env is passed through `exec`.\n\n```python\ntask_env_config = EnvironmentConfig(\n    workdir=\"/workspace\",\n    env={\"DATABASE_URL\": \"postgres://...\"},\n)\n```\n\n**Have a Dockerfile?** Reproduce its `RUN` / `COPY` / `WORKDIR` steps on Box as a\nruntime setup (outbound network works, so apt/pip/npm installs run). A complete,\nrunnable example is in\n[`examples/dockerfile_to_box.py`](examples/dockerfile_to_box.py).\n\n## Cleanup \u0026 billing\n\nHarbor stops the box as soon as a trial (one eval run) finishes — including when\nit errors — so a box only costs you while a trial is actually running. By default\n`stop()` removes the box (`delete=True`, matching Harbor); pass `delete=False` to\nkeep a resumable snapshot instead. Either way compute billing stops. The\n`ttl_seconds` you set is just a safety backstop for an abandoned box.\n\n## Isolation\n\nBoxes are **no-env by default**: a trial gets none of your Box account's secrets,\ncredentials, or cloned repos and can't act on your account or other boxes. Pass\n`no_env=False` to use your account's environment instead, configured in the\n[Box dashboard](https://box.ascii.dev/box/dashboard). See\n[Secrets \u0026 Setup](https://docs.ascii.dev/box/secrets).\n\n## Verify the adapter\n\nA self-contained end-to-end self-test exercises start → persistent/per-command\nenv vars → binary upload/download → nested directory upload/download → stop:\n\n```bash\nexport BOX_API_KEY=...\npython sdks/harbor_box_environment.py\n# -\u003e Box Harbor adapter e2e self-test PASSED\n```\n\nCI runs this self-test on every push.\n\n## Evals\n\nA from-scratch [Claude Agent SDK](https://github.com/anthropics/claude-agent-sdk-typescript)\ncoding agent solving tasks inside a Box, scored by inspecting the result. See\n[`sdks/harbor-box-evals/README.md`](sdks/harbor-box-evals/README.md).\n\n## Releasing\n\nMaintainers publish `harbor-box` to PyPI from a local checkout — see\n[`docs/release.md`](docs/release.md). CI never publishes.\n\n## License\n\n[MIT](LICENSE).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fariana-dot-dev%2Fharbor-box","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fariana-dot-dev%2Fharbor-box","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fariana-dot-dev%2Fharbor-box/lists"}