Skip to content

build(playground): publish a playground image served by Caddy - #1541

Merged
joshunrau merged 2 commits into
DouglasNeuroInformatics:mainfrom
joshunrau:ci/playground-image
Sep 14, 2026
Merged

joshunrau merged 2 commits into
DouglasNeuroInformatics:mainfrom
joshunrau:ci/playground-image

Conversation

@joshunrau

Copy link
Copy Markdown
Collaborator

Summary

  • Give the playground compose service an image: key (ghcr.io/douglasneuroinformatics/open-data-capture-playground). The release matrix already selects every service with both build and image, so release.yaml needs no edit and the playground image now ships alongside api, gateway and web, tagged latest and the bare version.
  • Replace the node + http-server runner with caddy:2.7-alpine serving the static dist/, using a Caddyfile identical to apps/web's (gzip/zstd, SPA fallback to index.html). The image carries no Node.
  • Move the build stages from node:iron to node:lts-krypton to satisfy the root engines field, matching the other app Dockerfiles.
  • Add the playground package to the Delete Package Versions workflow.
  • Update the release playbook (it stated no playground image ships) and apps/playground/AGENTS.md.

Side effect: docker compose --profile playground up now pulls the published image instead of building locally, like the other services.

Verification

  • docker compose config through the workflow's jq filter now yields four matrix legs including playground.
  • Built the image locally and ran it: 193 MB, no node binary; / and unknown paths return index.html; esbuild.wasm serves as application/wasm with gzip; JS and /runtime/v1/* serve as text/javascript.
  • Loaded it in a headless browser: the editor boots, esbuild-wasm initializes and the default instrument renders in the preview. A ~35 KB ?files= share link (pre-fix(playground-url): carry the share link payload in the URL fragment #1539 format) also opened correctly.
  • Not verified: the multi-arch (linux/amd64,linux/arm64) build and GHCR push, which first run in the Release workflow. No unit or e2e tests added; nothing in either suite exercises a Dockerfile or compose file.

🤖 Generated with Claude Code

joshunrau and others added 2 commits September 14, 2026 17:07
Give the compose playground service an image key so the release matrix builds and pushes
open-data-capture-playground alongside api, gateway and web. The runner stage is now
caddy:2.7-alpine serving the static dist instead of node with http-server, and the build
stages move from node:iron to node:lts-krypton to satisfy the repo's engines field.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01LuTyaGy7rvpBJ71mVKWnkv
@joshunrau
joshunrau merged commit 896eebd into DouglasNeuroInformatics:main Sep 14, 2026
2 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.

1 participant