{"id":49539591,"url":"https://github.com/danievanzyl/pyro","last_synced_at":"2026-05-02T14:02:31.931Z","repository":{"id":346769939,"uuid":"1187489054","full_name":"danievanzyl/pyro","owner":"danievanzyl","description":"Open-source Firecracker microVM sandbox platform for AI agents","archived":false,"fork":false,"pushed_at":"2026-03-25T20:09:17.000Z","size":4371,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-03-26T13:41:12.134Z","etag":null,"topics":["ai-agents","firecracker","golang","microvm","sandbox","svelte"],"latest_commit_sha":null,"homepage":"https://github.com/danievanzyl/pyro","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/danievanzyl.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-03-20T19:34:44.000Z","updated_at":"2026-03-26T04:59:25.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/danievanzyl/pyro","commit_stats":null,"previous_names":["danievanzyl/pyro"],"tags_count":10,"template":false,"template_full_name":null,"purl":"pkg:github/danievanzyl/pyro","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/danievanzyl%2Fpyro","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/danievanzyl%2Fpyro/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/danievanzyl%2Fpyro/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/danievanzyl%2Fpyro/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/danievanzyl","download_url":"https://codeload.github.com/danievanzyl/pyro/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/danievanzyl%2Fpyro/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32536582,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-02T12:25:33.646Z","status":"ssl_error","status_checked_at":"2026-05-02T12:24:51.733Z","response_time":132,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"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","firecracker","golang","microvm","sandbox","svelte"],"created_at":"2026-05-02T14:02:25.752Z","updated_at":"2026-05-02T14:02:31.924Z","avatar_url":"https://github.com/danievanzyl.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003cp align=\"center\"\u003e\n  \u003cimg src=\"assets/banner.png\" alt=\"Pyro — Firecracker microVM sandboxes for AI agents\" width=\"900\" /\u003e\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n  \u003ca href=\"https://github.com/danievanzyl/pyro/actions\"\u003e\u003cimg src=\"https://github.com/danievanzyl/pyro/actions/workflows/ci.yml/badge.svg\" alt=\"CI\"\u003e\u003c/a\u003e\n  \u003ca href=\"https://goreportcard.com/report/github.com/danievanzyl/pyro\"\u003e\u003cimg src=\"https://goreportcard.com/badge/github.com/danievanzyl/pyro\" alt=\"Go Report\"\u003e\u003c/a\u003e\n  \u003ca href=\"LICENSE\"\u003e\u003cimg src=\"https://img.shields.io/badge/license-MIT-blue.svg\" alt=\"License\"\u003e\u003c/a\u003e\n  \u003ca href=\"https://pypi.org/project/pyrovm-sdk/\"\u003e\u003cimg src=\"https://img.shields.io/pypi/v/pyrovm-sdk?label=pyrovm-sdk\" alt=\"PyPI\"\u003e\u003c/a\u003e\n  \u003ca href=\"https://www.npmjs.com/package/@pyrovm/sdk\"\u003e\u003cimg src=\"https://img.shields.io/npm/v/@pyrovm/sdk?label=@pyrovm/sdk\" alt=\"npm\"\u003e\u003c/a\u003e\n\u003c/p\u003e\n\n## Features\n\n- **Fast** — sub-second sandbox creation with snapshot pools\n- **Isolated** — each sandbox is a Firecracker microVM with its own kernel\n- **Simple API** — REST + WebSocket + SSE for sandbox lifecycle\n- **Multi-image** — default, minimal, ubuntu, python, node base images\n- **SDKs** — Python and TypeScript clients\n- **Dashboard** — built-in SvelteKit UI for fleet management\n- **Observability** — OpenTelemetry metrics, Prometheus endpoint, audit log\n\n## Quickstart\n\n### Python\n\n```bash\npip install pyrovm-sdk\n```\n\n```python\nimport asyncio\nfrom pyro_sdk import Pyro\n\nasync def main():\n    pyro = Pyro(api_key=\"pk_...\", base_url=\"http://localhost:8080\")\n\n    async with await pyro.sandbox.create(image=\"python\") as sb:\n        result = await sb.run(\"print('Hello from Pyro!')\")\n        print(result.stdout)\n\nasyncio.run(main())\n```\n\n### TypeScript\n\n```bash\nnpm install @pyrovm/sdk\n```\n\n```typescript\nimport { Pyro } from '@pyrovm/sdk'\n\nconst pyro = new Pyro({ apiKey: 'pk_...', baseUrl: 'http://localhost:8080' })\nconst sandbox = await pyro.sandbox.create({ image: 'python', timeout: 300 })\nconst result = await sandbox.run('print(\"Hello from Pyro!\")')\nconsole.log(result.stdout)\nawait sandbox.stop()\n```\n\n### CLI\n\n```bash\nexport PYRO_API_KEY=pk_...\npyro sandbox create --image python --ttl 300\npyro sandbox exec \u003cid\u003e python3 -c \"print('hello')\"\npyro sandbox kill \u003cid\u003e\n```\n\n## Architecture\n\n```\n┌─────────────┐     ┌──────────────┐     ┌─────────────────┐\n│  SDK / CLI  │────▶│  pyro-server │────▶│  Firecracker VM │\n│             │ HTTP│  (REST API)  │vsock│  (pyro-agent)   │\n└─────────────┘     └──────────────┘     └─────────────────┘\n                           │\n                    ┌──────┴──────┐\n                    │   SQLite    │\n                    │  (state DB) │\n                    └─────────────┘\n```\n\n- **pyro-server** — HTTP API server managing VM lifecycle, auth, quotas, and file operations\n- **pyro-agent** — runs as PID 1 inside each VM, handles exec/file commands over vsock\n- **pyro** — CLI for host setup, image building, and sandbox operations\n\n## API Endpoints\n\n| Method | Path | Description |\n|--------|------|-------------|\n| `POST` | `/api/sandboxes` | Create sandbox |\n| `GET` | `/api/sandboxes` | List sandboxes |\n| `GET` | `/api/sandboxes/{id}` | Get sandbox |\n| `DELETE` | `/api/sandboxes/{id}` | Destroy sandbox |\n| `POST` | `/api/sandboxes/{id}/exec` | Execute command |\n| `PUT` | `/api/sandboxes/{id}/files/*` | Write file |\n| `GET` | `/api/sandboxes/{id}/files/*` | Read file |\n| `GET` | `/api/sandboxes/{id}/ws` | WebSocket streaming exec |\n| `GET` | `/api/images` | List images |\n| `POST` | `/api/images` | Create image from Dockerfile |\n| `GET` | `/api/events` | SSE event stream |\n| `GET` | `/api/health` | Health check |\n\n## Self-hosting\n\nRequires a Linux host with KVM support.\n\n```bash\n# One-command setup (kernel, images, bridge, systemd)\nsudo pyro setup\n\n# Create an API key\npyro create-key my-key\n\n# Start the server\nsystemctl start pyro\n```\n\n### Build from source\n\n```bash\nmake build          # build all binaries\nmake build-linux    # cross-compile for Linux\nmake deploy         # build + SCP to remote host\n```\n\n## Images\n\n| Image | Size | Includes |\n|-------|------|----------|\n| `minimal` | 50 MB | Alpine base, busybox |\n| `default` | 50 MB | Alpine + common tools |\n| `ubuntu` | ~512 MB | Ubuntu 24.04 + git, curl, python3 |\n| `python` | ~512 MB | Python 3.12 + pip, requests, httpx |\n| `node` | ~512 MB | Node.js 22 + npm, corepack |\n\nBuild custom images from Dockerfiles:\n\n```bash\npyro build-image \u003cname\u003e\n# or via API:\ncurl -X POST /api/images -d '{\"name\":\"custom\",\"dockerfile\":\"...\"}'\n```\n\n## Configuration\n\n### Environment variables\n\n| Variable | Description | Default |\n|----------|-------------|---------|\n| `PYRO_API_KEY` | API key for SDK/CLI | — |\n| `PYRO_BASE_URL` | Server URL | `http://localhost:8080` |\n| `PYRO_DB` | SQLite database path | `/opt/pyro/db/pyro.db` |\n| `PYRO_IMAGES` | Images directory | `/opt/pyro/images` |\n\n### Server flags\n\n```\n--listen          API listen address (default :8080)\n--db              SQLite path\n--images-dir      Base images directory\n--max-sandboxes   Max concurrent VMs (default 100)\n--max-per-key     Max VMs per API key (default 10)\n--rate-limit      Creates per minute per key (default 30)\n--pool-size       Warm snapshot pool per image (default 0)\n--prometheus      Enable /metrics endpoint\n```\n\n## SDKs\n\n| SDK | Package | Docs |\n|-----|---------|------|\n| Python | [`pyrovm-sdk`](sdk/python/) | [README](sdk/python/README.md) |\n| TypeScript | [`@pyrovm/sdk`](sdk/typescript/) | [README](sdk/typescript/README.md) |\n\n## Examples\n\n- [Code Runner](examples/code-runner/) — run user-provided Python code in isolated sandboxes\n- [LangChain Agent](examples/langchain-agent/) — give an LLM agent a sandboxed code execution tool\n\n## License\n\nMIT\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdanievanzyl%2Fpyro","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdanievanzyl%2Fpyro","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdanievanzyl%2Fpyro/lists"}