CLAUDE.md: the home page deploys with wrangler and an API token from /src/.envrc
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
21
CLAUDE.md
21
CLAUDE.md
@@ -82,13 +82,20 @@ docker compose -f /mnt/fast/arcane/projects/ipx/compose.yaml up -d ipx-web
|
||||
```
|
||||
|
||||
The home page (`site/`, #216) is not on Tower. `sh site/build.sh` puts it in `site/dist` with the
|
||||
typeface, logo and icon from `web/`, and it goes to the Cloudflare Pages project `ipxreader` by
|
||||
direct upload, since there is no wrangler login here: hash each file as wrangler does (BLAKE3 of
|
||||
its base64 contents plus its extension, the first 32 hex digits, with the `blake3-wasm` package),
|
||||
ask the project for an upload token (`GET .../pages/projects/ipxreader/upload-token`), send the
|
||||
files to `/pages/assets/upload` with that token, then create a deployment
|
||||
(`POST .../pages/projects/ipxreader/deployments`) with the manifest of paths and hashes and
|
||||
`_headers`. Its screenshots (`site/shots`) come from a scratch iPX on public feeds, never
|
||||
typeface, logo and icon from `web/`, and it goes to the Cloudflare Pages project `ipxreader` with
|
||||
wrangler, which takes `CLOUDFLARE_API_TOKEN` and `CLOUDFLARE_ACCOUNT_ID` from `/src/.envrc` in
|
||||
place of a login:
|
||||
|
||||
```sh
|
||||
sh site/build.sh
|
||||
. /src/.envrc && npx -y wrangler@4.150.0 pages deploy site/dist --project-name ipxreader --branch main --commit-hash "$(git rev-parse HEAD)"
|
||||
curl -sL https://ipxreader.app/ | head -5
|
||||
```
|
||||
|
||||
`--branch main` makes it the production deployment that ipxreader.app serves; another branch is a
|
||||
preview at its own `*.ipxreader.pages.dev` address. The token is an account API token with
|
||||
Cloudflare Pages: Edit on this account and nothing else (dashboard, My Profile, API Tokens). If it
|
||||
is missing or expired, ask the owner for one rather than working around it. Its screenshots (`site/shots`) come from a scratch iPX on public feeds, never
|
||||
production's, which would show whose subscriptions are whose.
|
||||
|
||||
Testing sign-in from Tower itself proves nothing about the tunnel: Tower's own requests reach the
|
||||
|
||||
Reference in New Issue
Block a user