feat(demo): demo.pcbjam.com deploy — versioned WASM CDN + static gallery + tag CI
Cross-origin WASM CDN (cdn.pcbjam.com, R2): per-tool content-addressed, immutable folders + a per-release runtime manifest (snapshot from registry). boot.ts loads pthread workers cross-origin via a same-origin blob shim. Static no-backend project source (demo gallery; Save downloads to local), api.uploadFileBytes kept and config-gated. demo.pcbjam.com on Cloudflare Pages. deploy-demo.yml (tag v*) snapshots WASM + content + builds + deploys; publish-wasm.yml builds on Ubicloud. Design/spec docs live in pcbjam-private. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
5ff9f1c7b8
commit
5aae2a0d16
23 changed files with 1489 additions and 112 deletions
|
|
@ -5,11 +5,27 @@
|
|||
# local-folder loader on the home page.
|
||||
VITE_API_BASE_URL=http://localhost:3060
|
||||
|
||||
# Where the WASM glue/artifacts are served from. SAME-ORIGIN "/wasm" is required
|
||||
# (KiCad WASM pthread workers cannot be created cross-origin). On `dev` the
|
||||
# artifacts are symlinked into public/wasm and served by Vite at /wasm. For prod,
|
||||
# set an absolute URL whose origin also satisfies the COEP/COOP rules.
|
||||
VITE_WASM_ASSET_BASE_URL=/wasm
|
||||
# Where PROJECTS come from: "remote" (default — the @pcbjam/shared backend above)
|
||||
# or "static" (a read-only example gallery served from a CDN, NO backend — the
|
||||
# demo.pcbjam.com mode; editor saves download to local). For "static" you must
|
||||
# also set VITE_PROJECT_MANIFEST_URL.
|
||||
# VITE_PROJECT_SOURCE=static
|
||||
# VITE_PROJECT_MANIFEST_URL=https://cdn.pcbjam.com/content/2.7.7/manifest.json
|
||||
|
||||
# WASM asset root (no trailing slash). On `dev` the artifacts are symlinked into
|
||||
# public/wasm and served by Vite at /wasm (a FLAT layout — files live directly
|
||||
# under the root). For a prod CDN set an absolute URL, e.g.:
|
||||
# VITE_WASM_ROOT=https://cdn.pcbjam.com/wasm
|
||||
# A cross-origin CDN works: boot.ts loads the pthread worker via a same-origin
|
||||
# blob shim, and the CDN must send CORP: cross-origin + ACAO (+ COEP/COOP on the
|
||||
# app). VITE_WASM_ASSET_BASE_URL is the legacy name and is still honored.
|
||||
VITE_WASM_ROOT=/wasm
|
||||
|
||||
# Per-release WASM manifest file under VITE_WASM_ROOT (e.g. "manifest-2.7.7.json").
|
||||
# When set, the editor resolves each tool's versioned, content-addressed folder
|
||||
# (VITE_WASM_ROOT/<tool>/<ver>/) from it at runtime (see docs/features/demo-deploy).
|
||||
# Leave UNSET for the flat dev layout above.
|
||||
# VITE_WASM_MANIFEST=manifest-2.7.7.json
|
||||
|
||||
# Override the artifact source dir the dev symlink points at (default:
|
||||
# <repo>/tests/apps/kicad). Useful when serving prebuilt artifacts from elsewhere.
|
||||
|
|
|
|||
Loading…
Reference in a new issue