Skip to content

build(compose): move browserless to the v2 image and connect over CDP [10m after #78] - #77

Draft
Gl4dr3x wants to merge 1 commit into
claude/i-70-compose-hardening-ea3cfdfrom
claude/i-27-browserless-v2
Draft

Gl4dr3x wants to merge 1 commit into
claude/i-70-compose-hardening-ea3cfdfrom
claude/i-27-browserless-v2

Conversation

@Gl4dr3x

@Gl4dr3x Gl4dr3x commented Oct 26, 2026 •

Copy link
Copy Markdown
Collaborator

Gap: The browserless service runs browserless/chrome, Browserless v1 on Docker Hub, built in February 2024. The synced code (#78) connects to it differently, and real-browser is no longer read.

Change: browserless uses ghcr.io/browserless/chromium:v2.57.3, with TOKEN from the Coolify variable BROWSERLESS_TOKEN (:?, so a deploy is blocked while it is empty). rsshub gets PLAYWRIGHT_CDP_ENDPOINT: ws://browserless:3000?token=… from the same variable, replacing PUPPETEER_WS_ENDPOINT. The /pressure healthcheck sends the token. PUPPETEER_REAL_BROWSER_SERVICE and the real-browser service are removed. Endpoint format, token wiring and healthcheck are copied from upstream's docker-compose.yml as it stands on the #78 branch.

Order: This PR works only together with or after #78, which adds PLAYWRIGHT_CDP_ENDPOINT handling; the base is the branch of #76, because removing real-browser replaces #76's expose change for that service. Before #78, the old code reads PUPPETEER_WS_ENDPOINT only and gets no browser.

Before merge, in Coolify:

  1. Set BROWSERLESS_TOKEN to a new random value.
  2. Deploy this branch with the chore: merge DIYgod/RSSHub master into the fork [20m] #78 code as a test deployment.
  3. Check that browserless is healthy.
  4. Fetch routes that render through the remote browser; in the synced code 128 routes import @/utils/playwright, among them /bilibili/ranking/all, /apkpure/versions/jp.co.craftegg.band/jp and /chinatimes/realtimenews. The fork's own routes use no browser. Each should return items, not an error.

Rollback is a revert and a redeploy.

Unverified: ${BROWSERLESS_TOKEN:?} under Coolify (docs only), and the v2.57.3 tag (taken from the GHCR listing, not run). Upstream's own default value for the token is replaced by :?. Nothing was run on a Docker host.

Verified: pre-commit hook run with lint-staged (it skips *.yml, so it changed nothing in this file); oxfmt --check clean on the file.

Refs workoho/hostwarden-workspace#27. Not closed until the test routes pass.

🤖 Generated with Claude Code

@Gl4dr3x Gl4dr3x self-assigned this Oct 26, 2026
@Gl4dr3x

Gl4dr3x commented Oct 26, 2026

Copy link
Copy Markdown
Collaborator Author

On hold until the upstream sync for workoho/hostwarden-workspace#29 is merged. The fork's lib/utils/playwright.ts sets a launch-options connect parameter that Browserless v2 likely rejects, and the sync replaces that code. This PR stays a draft and gets reworked against the synced code; until then it is not deployed or merged.

An AI agent wrote this text in my name, on my instructions.

Run ghcr.io/browserless/chromium pinned to v2.57.3 instead of the v1 image
browserless/chrome. v2 refuses connections without a token, so the service
takes TOKEN from BROWSERLESS_TOKEN and rsshub passes it in
PLAYWRIGHT_CDP_ENDPOINT, the variable the synced code reads. The healthcheck
sends the token too. The real-browser service and PUPPETEER_REAL_BROWSER_SERVICE
go away, since the synced code no longer reads it.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
@Gl4dr3x
Gl4dr3x force-pushed the claude/i-27-browserless-v2 branch from efbdd11 to abd98fa Compare October 26, 2026 23:38
@Gl4dr3x Gl4dr3x changed the title build(compose): move browserless to the v2 image with a token [10m] build(compose): move browserless to the v2 image and connect over CDP [10m after #78] Oct 26, 2026
@Gl4dr3x
Gl4dr3x changed the base branch from master to claude/i-70-compose-hardening-ea3cfd October 26, 2026 23:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant