infra/docs/adr
Viktor Barzin a6b52a5839
Some checks are pending
Build infra CLI / build (push) Waiting to run
ci/woodpecker/push/default Pipeline was successful
homelab v0.8.0: browser verbs for headful anti-bot web automation
Add `homelab browser run|open` so agents can drive the cluster's headful
Chrome (chrome-service) over CDP from the devvm. The headless playwright/mcp
browser can load anti-bot sites and fill their forms, but the gated submit
silently fails — e.g. the Stirling Ackroyd Fixflo tenant portal returned
net::ERR_FILE_NOT_FOUND on its pre-submit check and hung, creating nothing.
Driving the real headful Chrome submits first try. That capability already
existed but was undiscoverable, so it cost ~40 min + redundant form re-runs to
find; now it is one command, versioned, test-covered, and `browser --help`
carries the when-to-use signature + an error-code cheat-sheet so the right tool
is reached at the right moment (the failure was judgment, not setup).

- port-forward svc/chrome-service:9222 (tunnels API-server->pod, so it bypasses
  the :9222 NetworkPolicy), assert non-headless via /json/version,
  connect_over_cdp, inject the same vendored stealth.js the in-cluster callers
  use; the port-forward is always torn down, on success and on error.
- node CDP client pinned to playwright-core@1.48.2 to match the v1.48.0-noble
  image (Chromium 130); self-provisioned lazily into ~/.cache/homelab, no
  per-user setup.
- default is a fresh incognito context (safe for the shared browser + concurrent
  callers); --shared-context reuses the warmed persistent profile.
- TDD: cmd_browser_test.go covers arg parsing, headless detection, the version
  pin, the help cheat-sheet, and a stealth.js drift guard. Verified end-to-end
  against bot.sannysoft.com (real Chrome UA, webdriver hidden, plugins/WebGL
  spoofed) and `browser open`.
- docs: README v0.8 section, ADR-0013, and a chrome-service.md "driving from
  outside the cluster" section.

Closes: code-nepg

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-06-22 12:22:22 +00:00
..
0001-android-emulator-in-cluster.md android-emulator: new stack — shared in-cluster Android 16 testing instance 2026-06-11 19:51:57 +00:00
0002-all-image-builds-off-infra-gha-ghcr.md docs: ADR-0002 — all owned image builds move off-infra to GHA + ghcr [ci skip] 2026-06-12 19:55:47 +00:00
0003-keep-forgejo-canonical-complete-mirror.md docs(adr-0003): keep Forgejo canonical, complete the GitHub mirror (reject swap) 2026-06-15 21:32:28 +00:00
0004-homelab-unified-cli.md homelab: v0.1 docs, distribution wiring, and version 2026-06-18 19:25:51 +00:00
0005-homelab-v01-scope.md homelab: v0.1 docs, distribution wiring, and version 2026-06-18 19:25:51 +00:00
0006-homelab-work-and-tf.md homelab: v0.1 docs, distribution wiring, and version 2026-06-18 19:25:51 +00:00
0007-homelab-k8s-verbs.md homelab: v0.2.0 — docs + version for the k8s verb-group 2026-06-18 22:30:41 +00:00
0008-homelab-memory-verbs.md homelab: add memory verb-group (v0.3.0) — direct claude-memory HTTP client 2026-06-19 05:56:25 +00:00
0009-homelab-ci-deploy-verbs.md homelab: v0.4.0 — ci/deploy verbs (watch what you trigger) 2026-06-19 10:59:14 +00:00
0010-homelab-net-obs-verbs.md homelab: v0.5.0 — net/dns/metrics/logs probes (endpoint resolution) 2026-06-19 11:27:31 +00:00
0011-homelab-usage-telemetry.md homelab: v0.6.0 — usage telemetry (usage top), evidence-driven verb prioritization 2026-06-19 22:29:01 +00:00
0012-homelab-ha-verbs.md homelab ha token: dedicated openclaw/ha-tokens secret + least-priv RBAC for emo 2026-06-21 10:45:32 +00:00
0013-homelab-browser-verbs.md homelab v0.8.0: browser verbs for headful anti-bot web automation 2026-06-22 12:22:22 +00:00