Deployment Matrix
Use this matrix to compare where the docs site, Node SSR storefront, Cloudflare sketch, webhooks, and maintenance tasks run. It is not a deployment tutorial; follow the linked guides for implementation steps.
| Target | What works | Host-owned checks |
|---|---|---|
| GitHub Pages docs site | This Starlight docs repo builds static docs for the custom domain root https://mika.bnomei.com. |
Internal docs links should stay root-safe; LLM routes should emit canonical URLs. |
| Astro Node SSR storefront | Seeded template uses @astrojs/node, output: "server", SQLite, local media, React, EmDash, Mika, and the actions provider. |
Node version, persistent disk/database, secrets, reverse proxy, scheduled task runner, raw-body webhook routing. |
| Astro Cloudflare Worker | Seeded template includes inactive *.cf variant files for @astrojs/cloudflare, D1, R2, and a template-specific Worker loader binding. |
Create real D1/R2 resources, replace placeholders, wire Cron Trigger/scheduled handler, validate adapter and loader compatibility. |
| Hybrid/static Astro | Static product pages can coexist with dynamic Mika pages. | Copied request-bound pages and endpoints need prerender = false or server output. |
| Provider webhooks | Host Astro endpoint forwards raw request to Mika webhook operation. | Preserve raw body, configure provider secret, monitor retries/failures, dedupe by provider evidence. |
| Maintenance | Mika plugin registers mika_maintenance schedule metadata and runtime runner for email outbox, stuck email leases, raw webhook payload retention, ACP sessions, stock, ephemeral rows, account-delete requests, and stuck workflows. |
Ensure the deployment platform actually invokes scheduled tasks and logs skipped/failed subtasks. |
Node Template Baseline
Section titled “Node Template Baseline”The seeded template’s local config uses:
output: "server";@astrojs/nodestandalone adapter;emdashSQLite database at./.emdash/mika-template.sqlite;- local media storage under
./.emdash/uploads; @bnomei/emdash-actionsprovider registration;- Mika native plugin entrypoint
#mika-template-plugin.
Cloudflare Variant Status
Section titled “Cloudflare Variant Status”The Cloudflare variant files are sketches, not active production defaults. They swap to:
@astrojs/cloudflare;- D1 binding
DB; - R2 binding
MEDIA; - template-specific Worker loader binding
LOADER; nodejs_compat;- Worker entry at
src/worker.ts.
Copying variant files overwrites real package.json, astro.config.mjs, wrangler.jsonc, and src/worker.ts in the target app. Commit or branch first.
Next: Deployment And Maintenance covers the scheduled task. Cloudflare Variant covers the inactive Worker/D1/R2 sketch.
External References
Section titled “External References”- Astro on-demand rendering for adapter and
output: "server"requirements. - Astro Cloudflare adapter for Cloudflare-specific adapter behavior.
- Cloudflare Workers Astro guide for current Workers setup notes.
- Cloudflare D1 for the D1 storage model referenced by the variant sketch.
Source Anchors
Section titled “Source Anchors”astro.config.mjs- ⓣ
../emdash-mika-template/astro.config.mjs - ⓣ
../emdash-mika-template/package.json - ⓣ
../emdash-mika-template/astro.config.cf.mjs - ⓣ
../emdash-mika-template/package.cf.json - ⓣ
../emdash-mika-template/wrangler.cf.jsonc - ⓣ
../emdash-mika-template/worker.cf.ts - ⓟ
../emdash-mika/src/plugin.ts - ⓟ
../emdash-mika/src/api/maintenance.ts