Deploy Bun to real AWS in 5 minutes.
Push a Bun (Hono / Elysia / native HTTP) repo to Lander. Bun's fast cold-start + native TypeScript mean sub-200ms deploys on per-customer Fargate.[walkthrough · 5 minutes]
01
Bun's official image is at oven/bun. Use the Alpine variant for a smaller container — under 50 MB compressed.Add a Dockerfile using oven/bun
# Dockerfile FROM oven/bun:1-alpine WORKDIR /app COPY package.json bun.lockb* ./ RUN bun install --frozen-lockfile COPY . . ENV PORT=80 EXPOSE 80 CMD ["bun", "run", "start"]
02
Bun's native HTTP server reads PORT from env. For Hono / Elysia, the framework handles it.Listen on $PORT in your handler
// Bun native
Bun.serve({ port: process.env.PORT ?? 80, fetch(req) { return new Response("hello") } })
// Hono
import { Hono } from "hono"
const app = new Hono()
app.get("/", (c) => c.text("hello"))
export default { port: process.env.PORT ?? 80, fetch: app.fetch }03
lander.host/onboard, install GitHub App, point at repo. CodeBuild handles the docker build. Bun installs are fast — full deploy ~3 minutes.Sign up + push
[why · lander vs vercel · railway · render]
- →Per-customer Fargate at 0.25 vCPU is plenty for Bun's lightweight runtime.
- →ARM64 Graviton2 default — Bun runs natively on ARM with full perf.
- →AI Bug Hunter flags common Bun pitfalls (open file handles, unbounded fetch) on every deploy.
[gotchas]
- ·bun install --frozen-lockfile requires bun.lockb committed. Commit it (Bun's lockfile is binary but small).
- ·Bun's native fetch() doesn't share connection pools the way Node's http.Agent does — long-running tasks may need explicit pool management.
- ·Some npm packages with native bindings (esbuild, sharp) need Bun-compatible builds. Test locally before deploy.
[other stacks · same flow]