Skip to content

example: add Bun Hono example - #876

Merged
bnusunny merged 5 commits into
aws:mainfrom
mattenarle10:example/bun-hono
Nov 17, 2026
Merged

bnusunny merged 5 commits into
aws:mainfrom
mattenarle10:example/bun-hono

Conversation

@mattenarle10

@mattenarle10 mattenarle10 commented Oct 8, 2026 •

Copy link
Copy Markdown
Contributor

Issue #, if available: N/A

Description of changes:

This PR adds examples/bun-hono. It runs a Hono application on Bun in a container image with Lambda Web Adapter. The application is a Bun HTTP server in TypeScript with no build step.

Changes:

  • examples/bun-hono: the application, the Dockerfile, the SAM template, and a README.
  • .github/example-matrix.json: an image entry, so Verify Examples builds and boots the example.
  • .github/dependabot.yml: an npm entry for /examples/bun-hono/app.
  • README.md and docs/guide/src/examples/overview.md: the example is in the two lists.

The Dockerfile starts from the Node.js image on Amazon ECR Public and installs Bun with npm. Bun has no official image on ECR Public, and the examples do not pull from Docker Hub (#752).

GET / returns the request ID and the function name, not the full request context and Lambda context. The full contexts contain the AWS account ID.

This is a companion to #875 (Hono in Zip). The two PRs do not change the same lines.

Original verification (October 9):

Refresh verification (2026-11-09)

I merged upstream b6a089b and kept the existing maintainer merge commit. The example files are unchanged.

The example workflow remains red because its global template validator fails with E6101/E1010 on examples/fastapi-response-streaming-lmi/template.yaml. That template and its validation workflow are unchanged from upstream.

I also checked the app routes, context headers, 404s, shutdown, local SAM validation, and a read-only non-root container. The original AWS deployment verification above was on October 9. I did not deploy AWS resources for this refresh.

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

Run a Hono app on Bun in a container image behind Lambda Web Adapter.
The Dockerfile installs Bun with npm on the Node.js image from ECR
Public, because Bun has no official image there. Add the example to the
image matrix so Verify Examples builds and boots it, and claim its
manifest in dependabot.yml.
@mattenarle10
mattenarle10 requested a review from a team as a code owner October 8, 2026 17:18
@mattenarle10

Copy link
Copy Markdown
Contributor Author

I refreshed the branch from upstream and kept the existing maintainer merge commit. The example files are unchanged.

Fresh core CI passed 98 tests and both layer builds. All 19 runtime checks passed, including this Hono example.

The global template validator still fails on the unchanged fastapi-response-streaming-lmi example (E6101/E1010).

Could you approve the fresh upstream workflow runs? Thank you!

@bnusunny bnusunny left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @mattenarle10, nice example. It uses ECR Public only (per #752), a frozen lockfile and --production installs, the transpiler cache is off for the read-only filesystem, and it doesn't echo the full contexts. sam validate --lint and check-example-config.sh pass locally, and the lockfile has no known advisories.

The validate failure on fastapi-response-streaming-lmi is pre-existing on main.

@bnusunny
bnusunny merged commit 8bc620a into aws:main Nov 17, 2026
50 of 52 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants