nandi/frqpublic Fork 0
bd10e816d10d09c3dbe1256c1b7c661d8e190ee6
Commits
Clone
git clone https://git.rickub.com/nandi/frq.git
git clone ssh://git@rickub.com/nandi/frq.git

Host key fingerprint (ed25519): SHA256:iycHnxEyq0Q7uyVpB7JlznP0G7JrTPXLYRcAU5CSLhc — verify it before your first connect.

README.md · 39 lines · 1.9 KBmarkdown Blame HistoryRaw
CI builds the image, Modal serves it 5693bd5 nandi 15h ago1# `web`
2
The registry it pushes to is the one it has 627b785 nandi 14h ago3 FRQ_WEB_IMAGE=registry.rickub.com/nandi/frq-web:<sha> \
The web container is plain Modal bd10e81 nandi 14h ago4 modal deploy .modal/web/app.py
CI builds the image, Modal serves it 5693bd5 nandi 15h ago5
The web container is plain Modal bd10e81 nandi 14h ago6Plain Modal, in `app.py`. There is no `container.toml` here and no
7`_loader.py` behind it: `dev` has a spec because it is a sandbox
8with a volume, a toolchain and a command that changes, and this is
9four constants and a `Popen`.
CI builds the image, Modal serves it 5693bd5 nandi 15h ago10
The registry it pushes to is the one it has 627b785 nandi 14h ago11Unlike `dev`, this container builds nothing. rickub builds the image
12-- `Dockerfile` here, two stages, the second one just the bundle and
13a python -- and pushes it to `registry.rickub.com`; this deploys that
CI builds the image, Modal serves it 5693bd5 nandi 15h ago14exact tag. So the thing served is the thing that was built and
The registry it pushes to is the one it has 627b785 nandi 14h ago15tested, and a deploy is a pull rather than a compile. The workflow is
16`.rickub/workflows/web.yml`.
CI builds the image, Modal serves it 5693bd5 nandi 15h ago17
The web container is plain Modal bd10e81 nandi 14h ago18`@modal.web_server`: a Function whose command listens on a port,
19fronted by a stable https URL. Modal waits for the port to accept a
20connection and then proxies to it, which is why the command is a
21`Popen` that keeps running rather than a `run` that finishes.
22`modal deploy` leaves it up, and deploying again replaces it in
23place because `modal.App("frq-web")` names it.
CI builds the image, Modal serves it 5693bd5 nandi 15h ago24
Nothing to guard, so no credential to keep 5581b0f nandi 14h ago25One credential and one setting live outside the repo, both one-time:
CI builds the image, Modal serves it 5693bd5 nandi 15h ago26
The registry it pushes to is the one it has 627b785 nandi 14h ago27* `MODAL_TOKEN_ID` / `MODAL_TOKEN_SECRET`, as rickub repository
Nothing to guard, so no credential to keep 5581b0f nandi 14h ago28 secrets. The registry needs none of its own -- rickub authenticates
29 docker before a workflow's first step.
30* The image set to **public** on rickub: its detail page, Manage,
31 visibility. Private is the default, and the first push creates it
32 private, so this is done once after the first green run.
The registry it pushes to is the one it has 627b785 nandi 14h ago33
The web container is plain Modal bd10e81 nandi 14h ago34The second is why `from_registry` is called without a `secret`.
Nothing to guard, so no credential to keep 5581b0f nandi 14h ago35Modal pulls on every cold start rather than once at deploy time, so a
36private image would want a long-lived rickub deploy token held as a
37Modal Secret -- and what it would be guarding is `build/web`, which
38the URL hands to anyone who opens it. The alternative is written down
The web container is plain Modal bd10e81 nandi 14h ago39in `app.py` for whoever wants it.