Self-hosting
Every Wayglass project lives on a Worker that someone deploys to their own Cloudflare account. The step-by-step guide is kept with the code, so it changes together with the Worker:
docs/SELF-HOSTING.mdin the main repository.- The “Deploy your own Worker” section of the README covers the same ground in brief.
What it involves
Section titled “What it involves”- A Cloudflare account on the Workers Paid plan, which Artifacts requires.
- Artifacts namespaces for the jurisdictions you want to offer (for example one
usand oneeu). A namespace’s jurisdiction is fixed when it is created. - A Queue for Artifacts push events, so pushes to a trunk that skip
wayglass landshow up in the audit log. - Deploying the Worker in
worker/with the pinnednpx wrangler, then setting its admin key as a secret and logging in withwayglass login. - Optionally,
CF_ACCOUNT_IDandCF_EVENTS_API_TOKEN(an API token limited to Account › Queues › Edit), so the Worker can subscribe each new trunk to push events. Without them projects still work, andwayglass initwarns that trunk pushes are not watched. - Optionally,
PUBLIC_PROJECTSinwrangler.jsonc, if you want the web audit view to show any project.
The deployed Worker reaches Artifacts only through its bindings. It holds no Cloudflare API token with access to Artifacts; see the security model.
Artifacts bills per operation and per GB stored beyond the included amount (10,000 operations and 1 GB per month at the time of writing; check Artifacts pricing). Each intent creates one fork repo in Artifacts.