Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions pkgs/lab-ops-hub/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ sized to stay inside the $5/mo plan's included amounts ($0 overage by design):
| **Queues** (`labops-jobs`) | async file indexing (SHA-256 + mark indexed in D1) |
| **Durable Objects** (`LiveRoom`, SQLite) | live status board: WebSocket presence + broadcast, board persisted in DO SQLite |
| **Containers** (`CrawlerContainer`) | on-demand Python URL crawler; starts only when `/api/crawl` is called, `sleepAfter=2m` so idle minutes aren't burned. Worker-side fallback crawler with the same JSON contract if the container is unavailable |
| **Workers AI** | one-click note summarisation (`@cf/meta/llama-3.1-8b-instruct`, free-neuron allowance) |
| **Workers AI** | one-click note summarisation (`@cf/meta/llama-3.2-3b-instruct`, free-neuron allowance) |
| **Cron Triggers** | daily 04:23 UTC: trim usage ledger (90d), refresh KV snapshot |
| **Workers Assets** | the dashboard in `public/` |
| **Observability** | Workers Logs enabled in `wrangler.jsonc` |
Expand Down Expand Up @@ -96,7 +96,7 @@ wrangler containers registries credentials --push # prints a JWT
# 3. Push with crane, username = account id, password = that JWT
# (docker config auth entry for registry.cloudflare.com)
nix run nixpkgs#crane -- push <image.tar> \
registry.cloudflare.com/<account-id>/lab-ops-hub-crawlercontainer:latest
registry.cloudflare.com/<account-id>/lab-ops-hub-crawlercontainer:v3
# 4. wrangler.jsonc references the registry image (not ./Dockerfile),
# so `wrangler deploy` needs no Docker at all.
```
Expand Down Expand Up @@ -127,7 +127,7 @@ wrangler), plain `npm run deploy` with the Dockerfile form works too;
image. DO instances are sticky: a DO reuses its existing instance
across rollouts, which is why image bumps appeared to "not take".
If starts recover, the current config (image `:v3`, instance name
`crawler-2`) should serve crawls with `source='container'` in D1 —
`crawler-4`) should serve crawls with `source='container'` in D1 —
that row is the only accepted proof.
- The Worker falls back to its in-Worker crawler on any container error
and reports `container_error` in the response, so the API never
Expand Down
4 changes: 2 additions & 2 deletions pkgs/lab-ops-hub/container-image.nix
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Daemon-less OCI image for the Lab Ops Hub crawler container.
# nixpkgs is pinned to the same rev as dezren39/nix's flake.lock.
# Build: nix build -f container-image.nix -> store path is a docker-archive tar
# Push: crane push <tar> registry.cloudflare.com/<account>/lab-ops-hub-crawlercontainer:latest
# Push: crane push <tar> registry.cloudflare.com/<account>/lab-ops-hub-crawlercontainer:v3
# (or load it anywhere with docker/podman and `wrangler deploy` from there)
let
nixpkgs = fetchTarball {
Expand All @@ -12,7 +12,7 @@ let
in
pkgs.dockerTools.buildLayeredImage {
name = "lab-ops-hub-crawlercontainer";
tag = "latest";
tag = "v3";
contents = [
pkgs.python3
pkgs.cacert
Expand Down
Loading