Pick any line to see why it is the way it is: the commit, the pull request and issue it came from, and what the agent was thinking.
| g1t.page runs Docker deployments, behind a switch that is off until Cloudflare's container APIs are checked against g1t's account (`CONTAINERS` in the deployments service). Each container app is a Worker of g1t's own in the same Workers for Platforms namespace, so the dispatcher, custom domains, previews and take-downs reach it by name as any app: its `G1tApp` Durable Object holds a Container application (default scheduling policy, one instance, the project's **Container size**, `lite` unless chosen), starts it on the first request with the project's secrets and variables and `PORT` as its environment, waits up to 90 seconds for it to answer on its port, proxies to it, and stops it five minutes after the last request; it charges each minute awake ahead and the bytes it sends, and reports them with a token of its own to `POST /deployments/apps/<app>/meter`, which the API forwards. A build's new `registry` step gets a registry login g1t mints push-only for 15 minutes, with its app's own repository named; g1t runs only an image by digest in that repository, checked with the registry, and never hands a build a login that can pull. Container time is metered at Cloudflare's Containers price plus the margin through new price book meters (vCPU charged as busy while awake, and egress at the most a GB costs anywhere, so g1t never sells below cost), noted for the spend limit as it runs and charged with the month's Deployments line; a paused workspace's container apps stop and start no more. Settings, Deployments gets Build as (Auto, Static site, Workers, Docker), Dockerfile and Container size with each size's price an hour, and says what the last build found with what it was built with ("Static site · Astro", "Container · Dockerfile"), now that the finish report's `framework` is stored. Deploy sandboxes get Docker, `BUILD_AS` and `DOCKERFILE`, and reach `registry.cloudflare.com`; `start_deployment_build` answers `build_as` and `dockerfile` for `g1t/deploy`, which takes them as inputs, as `g1t/detect` does. The Deployments guide has Docker deployments, their prices and how they work with the evidence for it, the limitations page says what is left, and Deploy g1t to Cloudflare lists each live check to make before switching it on. | 1 | -- Docker deployments (src/containers.ts). |
| 2 | ||
| 3 | -- Each project's choices: what it is built as (auto, static, workers or | |
| 4 | -- docker), its Dockerfile's path when not one g1t finds by itself, and the | |
| 5 | -- size its container runs at (a Cloudflare Containers instance type). | |
| 6 | ALTER TABLE settings ADD COLUMN build_as TEXT NOT NULL DEFAULT 'auto'; | |
| 7 | ALTER TABLE settings ADD COLUMN dockerfile TEXT; | |
| 8 | ALTER TABLE settings ADD COLUMN instance_type TEXT NOT NULL DEFAULT 'lite'; | |
| 9 | ||
| 10 | -- What each build found the project built with, next to `detected`: a | |
| 11 | -- framework's id (`astro`), or for a container `dockerfile` or the server | |
| 12 | -- g1t wrote a Dockerfile for (`flask`). And a container's image, by digest. | |
| 13 | ALTER TABLE deployments ADD COLUMN framework TEXT; | |
| 14 | ALTER TABLE deployments ADD COLUMN image TEXT; | |
| 15 | ||
| 16 | -- An app that is a container: its Container application, the size it runs | |
| 17 | -- at, and the hash of the token its Worker reports its running time with. | |
| 18 | -- `runtime` is `worker` for every other app. | |
| 19 | ALTER TABLE apps ADD COLUMN runtime TEXT NOT NULL DEFAULT 'worker'; | |
| 20 | ALTER TABLE apps ADD COLUMN container_app_id TEXT; | |
| 21 | ALTER TABLE apps ADD COLUMN instance_type TEXT; | |
| 22 | ALTER TABLE apps ADD COLUMN meter_hash TEXT; | |
| 23 | ||
| 24 | -- How long each app's container ran in a month, and what it sent, as its | |
| 25 | -- Worker reports them: one row per counter (`epoch`, the Durable Object's | |
| 26 | -- own, which starts again at zero if it is ever new), each only ever | |
| 27 | -- raised, so a report repeated or out of order changes nothing. | |
| 28 | CREATE TABLE container_meters ( | |
| 29 | script TEXT NOT NULL, | |
| 30 | epoch TEXT NOT NULL, | |
| 31 | month TEXT NOT NULL, | |
| 32 | workspace TEXT NOT NULL, | |
| 33 | instance_type TEXT NOT NULL, | |
| 34 | awake_seconds INTEGER NOT NULL DEFAULT 0, | |
| 35 | egress_bytes INTEGER NOT NULL DEFAULT 0, | |
| 36 | reported_at TEXT NOT NULL, | |
| 37 | PRIMARY KEY (script, epoch, month) | |
| 38 | ); | |
| 39 | CREATE INDEX container_meters_by_month ON container_meters (month, workspace); |