Repository navigation
whim v0.1.0 — first release
Ephemeral AWS Lambda MicroVM shells — a Go library (microvm) and CLI (whim).
Spin up a throwaway root shell in a Firecracker MicroVM in ~2 seconds, run something, and let it disappear.
whim init # one-time: build the default sandbox image (~3 min)
whim # drop into a throwaway root shell
whim run -- pytest # spawn → run → stream output → propagate exit code → terminateWhat's in v0.1
Build once, run many. whim init provisions an S3 build bucket + IAM build role, then builds a default AL2023 image and caches its ARN. Every subsequent whim/whim run launches a fresh VM from that image in ~2s over an authenticated WebSocket, and terminates it on exit. Every VM carries a server-side TTL (default 25m, max 8h) as a cleanup backstop.
CLI:
- whim / whim shell — interactive root shell (Ctrl-] to disconnect)
- whim run -- <cmd…> — launch, run, stream output, propagate exit code, terminate
- whim exec -- <cmd…> — run a command in an existing VM
- whim put/whim get — copy files/dirs in or out (binary-safe, docker cp-style)
- whim ps / whim gc — list / bulk-terminate your whim VMs (docker ps-style)
- whim suspend/whim resume — pause/restart a VM with disk + memory intact
- whim image ls/whim image rm — manage built images
- whim init / whim preflight-check / whim version — bootstrap, checks, version
Library. microvm is the product; the CLI is a thin client. It's credential-injection-only (you pass an aws.Config — composes with IRSA, ECS task roles, aws-vault, assumed roles) and exposes Launch, Shell, Exec, Put/Get, Suspend/Resume, List/GC, all through typed sentinel errors.
Security model: shell tokens are never logged, credentials are injection-only, every VM always carries a TTL, and ps/gc are scoped to your own account's images (VMs can't be tagged, so ownership is ARN-derived). The id-targeted commands (exec, put, get, suspend, resume) act on any VM you explicitly name — like ssh , naming the target is the authorization.
Known v0.1 limitations
- Ownership is image-derived, not tagged — scope gc carefully if you run another tool against the same account's images.
- Exec output is combined stdout+stderr (a pty merges them).
- Interactive shells last ~30 min (the shell-token lifetime); no reconnect.
- Transfers are in-memory, capped at 256 MiB per put/get.
- Reconnect yields a new shell (disk persists, in-memory state does not).
- Terminal resize isn't forwarded yet.
Install
go install github.com/udgover/whim/cmd/whim@v0.1.0
aws login
whim preflight-check
whim initApache 2.0.
Full Changelog: https://github.com/udgover/whim/commits/v0.1.0