Title: bug: v4.4.6 self-hosted webapp fails to start due to ClickHouse URL `secure` param mismatch (goose entrypoint + Runs Replication client) · Issue #3674 · triggerdotdev/trigger.dev · GitHub
Open Graph Title: bug: v4.4.6 self-hosted webapp fails to start due to ClickHouse URL `secure` param mismatch (goose entrypoint + Runs Replication client) · Issue #3674 · triggerdotdev/trigger.dev
X Title: bug: v4.4.6 self-hosted webapp fails to start due to ClickHouse URL `secure` param mismatch (goose entrypoint + Runs Replication client) · Issue #3674 · triggerdotdev/trigger.dev
Description: Provide environment information Provide environment information Trigger.dev version: v4.4.6 (self-hosted Docker, ghcr.io/triggerdotdev/trigger.dev:v4.4.6) Setup: standard hosting/docker compose, multi-file (webapp/docker-compose.yml + wo...
Open Graph Description: Provide environment information Provide environment information Trigger.dev version: v4.4.6 (self-hosted Docker, ghcr.io/triggerdotdev/trigger.dev:v4.4.6) Setup: standard hosting/docker compose, mu...
X Description: Provide environment information Provide environment information Trigger.dev version: v4.4.6 (self-hosted Docker, ghcr.io/triggerdotdev/trigger.dev:v4.4.6) Setup: standard hosting/docker compose, mu...
Opengraph URL: https://github.com/triggerdotdev/trigger.dev/issues/3674
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"bug: v4.4.6 self-hosted webapp fails to start due to ClickHouse URL `secure` param mismatch (goose entrypoint + Runs Replication client)","articleBody":"### Provide environment information\n\n### Provide environment information\n\n- **Trigger.dev version:** `v4.4.6` (self-hosted Docker, `ghcr.io/triggerdotdev/trigger.dev:v4.4.6`)\n- **Setup:** standard `hosting/docker` compose, multi-file (`webapp/docker-compose.yml` + `worker/docker-compose.yml`)\n- **ClickHouse:** `bitnamilegacy/clickhouse:latest`, HTTP only (no TLS), port 8123, local container\n- **Host:** Linux amd64\n- **Previous working version:** `v4.4.5` (same `.env`, started healthy)\n\n### Describe the bug\n\nAfter updating the image tag from `v4.4.5` to `v4.4.6` and running `docker compose pull && up -d`, the `webapp` container enters a restart loop. Two separate ClickHouse-URL handling issues block startup, related to but not fully covered by #3184 / #3204.\n\n**Issue 1 — `entrypoint.sh` appends `?secure=true` unconditionally, goose now rejects it**\n\n`docker/scripts/entrypoint.sh` constructs `GOOSE_DBSTRING` from `CLICKHOUSE_URL` and adds `?secure=true` if `secure=` isn't already in the URL — regardless of scheme. When the URL uses `http://` (no TLS), the goose ClickHouse driver in v4.4.6 fails DSN parsing:\n\n```\n+ export GOOSE_DBSTRING=http://default:***@clickhouse:8123?secure=true\n+ /usr/local/bin/goose up\n2026/05/20 10:13:56 goose run: clickhouse [dsn parse]: http with TLS specify; clickhouse [dsn parse]: http with TLS specify\n```\n\nThis appears to be a behavior change in the goose ClickHouse driver between v4.4.5 and v4.4.6 — the same DSN was tolerated by the older driver. `entrypoint.sh` exits non-zero, container restarts forever.\n\n**Issue 2 — `RUN_REPLICATION_CLICKHOUSE_URL` is NOT stripped before being passed to `@clickhouse/client`**\n\n#3204 added stripping of the `secure` query param for `QUERY_CLICKHOUSE_URL`, but `RUN_REPLICATION_CLICKHOUSE_URL` follows the same path through `@clickhouse/client@1.12.1` and doesn't get the same treatment. Workarounding Issue 1 by adding `?secure=false` to `RUN_REPLICATION_CLICKHOUSE_URL` (because the main `CLICKHOUSE_URL` workaround value is reused as the replication URL in some setups) triggers:\n\n```\n🗃️ Runs replication service enabled\n{\"url\":\"http://default:redacted@clickhouse:8123/?secure=false\", ...}\nError: Unknown URL parameters: secure\n at loadConfigOptionsFromURL (.../config.js:267:19)\n at prepareConfigWithURL (.../config.js:42:34)\n at new ClickHouseClient (.../client.js:59:65)\n at createClient (.../@clickhouse+client@1.12.1/.../client.js:15:12)\n at new ClickhouseClient (.../webapp/build/index.js:49830:243)\n at new ClickHouse (.../webapp/build/index.js:63805:21)\n at initializeRunsReplicationInstance (.../webapp/build/index.js:190055:20)\n```\n\n### To reproduce\n\n1. Self-host `v4.4.5` with HTTP ClickHouse (no TLS), `CLICKHOUSE_URL=http://...@clickhouse:8123`, healthy.\n2. Bump `TRIGGER_IMAGE_TAG` to `v4.4.6`, `docker compose pull && up -d`.\n3. Observe `webapp` in restart loop, goose error in logs (Issue 1).\n4. Append `?secure=false` to `CLICKHOUSE_URL` and `RUN_REPLICATION_CLICKHOUSE_URL` — goose now passes, but webapp now crashes on Runs Replication init (Issue 2).\n\n### Workaround (currently running in production)\n\nAsymmetric values:\n\n```env\nCLICKHOUSE_URL=http://default:***@clickhouse:8123?secure=false\nRUN_REPLICATION_CLICKHOUSE_URL=http://default:***@clickhouse:8123\n```\n\n- `CLICKHOUSE_URL` ends with `?secure=false` so `entrypoint.sh`'s `grep -q secure=` matches and skips appending `?secure=true`. goose accepts `secure=false` + `http://` (no conflict). Webapp's own `CLICKHOUSE_URL` consumption already strips `secure` via #3204, so the param is harmless there.\n- `RUN_REPLICATION_CLICKHOUSE_URL` stays clean — it goes to `@clickhouse/client` without stripping.\n\nThis works but is fragile and undiscoverable.\n\n### Suggested fix\n\nTwo independent things to address:\n\n1. **`docker/scripts/entrypoint.sh`** — only append `?secure=true` when the URL scheme is `https://`. Or, simpler: strip the param entirely before calling `goose` and translate it to the scheme (`https://` → `secure=true`, `http://` → no flag). Conflating TLS choice with a query param when the scheme already encodes it is the root issue.\n\n2. **`initializeRunsReplicationInstance`** — apply the same `secure` strip that `QUERY_CLICKHOUSE_URL` got in #3204 to `RUN_REPLICATION_CLICKHOUSE_URL` (and any other URL passed to `@clickhouse/client`). Centralizing this in a helper used by all client constructors would prevent regressions.\n\n\n\n### Describe the bug\n\n### Provide environment information\n\n- **Trigger.dev version:** `v4.4.6` (self-hosted Docker, `ghcr.io/triggerdotdev/trigger.dev:v4.4.6`)\n- **Setup:** standard `hosting/docker` compose, multi-file (`webapp/docker-compose.yml` + `worker/docker-compose.yml`)\n- **ClickHouse:** `bitnamilegacy/clickhouse:latest`, HTTP only (no TLS), port 8123, local container\n- **Host:** Linux amd64\n- **Previous working version:** `v4.4.5` (same `.env`, started healthy)\n\n### Describe the bug\n\nAfter updating the image tag from `v4.4.5` to `v4.4.6` and running `docker compose pull && up -d`, the `webapp` container enters a restart loop. Two separate ClickHouse-URL handling issues block startup, related to but not fully covered by #3184 / #3204.\n\n**Issue 1 — `entrypoint.sh` appends `?secure=true` unconditionally, goose now rejects it**\n\n`docker/scripts/entrypoint.sh` constructs `GOOSE_DBSTRING` from `CLICKHOUSE_URL` and adds `?secure=true` if `secure=` isn't already in the URL — regardless of scheme. When the URL uses `http://` (no TLS), the goose ClickHouse driver in v4.4.6 fails DSN parsing:\n\n```\n+ export GOOSE_DBSTRING=http://default:***@clickhouse:8123?secure=true\n+ /usr/local/bin/goose up\n2026/05/20 10:13:56 goose run: clickhouse [dsn parse]: http with TLS specify; clickhouse [dsn parse]: http with TLS specify\n```\n\nThis appears to be a behavior change in the goose ClickHouse driver between v4.4.5 and v4.4.6 — the same DSN was tolerated by the older driver. `entrypoint.sh` exits non-zero, container restarts forever.\n\n**Issue 2 — `RUN_REPLICATION_CLICKHOUSE_URL` is NOT stripped before being passed to `@clickhouse/client`**\n\n#3204 added stripping of the `secure` query param for `QUERY_CLICKHOUSE_URL`, but `RUN_REPLICATION_CLICKHOUSE_URL` follows the same path through `@clickhouse/client@1.12.1` and doesn't get the same treatment. Workarounding Issue 1 by adding `?secure=false` to `RUN_REPLICATION_CLICKHOUSE_URL` (because the main `CLICKHOUSE_URL` workaround value is reused as the replication URL in some setups) triggers:\n\n```\n🗃️ Runs replication service enabled\n{\"url\":\"http://default:redacted@clickhouse:8123/?secure=false\", ...}\nError: Unknown URL parameters: secure\n at loadConfigOptionsFromURL (.../config.js:267:19)\n at prepareConfigWithURL (.../config.js:42:34)\n at new ClickHouseClient (.../client.js:59:65)\n at createClient (.../@clickhouse+client@1.12.1/.../client.js:15:12)\n at new ClickhouseClient (.../webapp/build/index.js:49830:243)\n at new ClickHouse (.../webapp/build/index.js:63805:21)\n at initializeRunsReplicationInstance (.../webapp/build/index.js:190055:20)\n```\n\n### To reproduce\n\n1. Self-host `v4.4.5` with HTTP ClickHouse (no TLS), `CLICKHOUSE_URL=http://...@clickhouse:8123`, healthy.\n2. Bump `TRIGGER_IMAGE_TAG` to `v4.4.6`, `docker compose pull && up -d`.\n3. Observe `webapp` in restart loop, goose error in logs (Issue 1).\n4. Append `?secure=false` to `CLICKHOUSE_URL` and `RUN_REPLICATION_CLICKHOUSE_URL` — goose now passes, but webapp now crashes on Runs Replication init (Issue 2).\n\n### Workaround (currently running in production)\n\nAsymmetric values:\n\n```env\nCLICKHOUSE_URL=http://default:***@clickhouse:8123?secure=false\nRUN_REPLICATION_CLICKHOUSE_URL=http://default:***@clickhouse:8123\n```\n\n- `CLICKHOUSE_URL` ends with `?secure=false` so `entrypoint.sh`'s `grep -q secure=` matches and skips appending `?secure=true`. goose accepts `secure=false` + `http://` (no conflict). Webapp's own `CLICKHOUSE_URL` consumption already strips `secure` via #3204, so the param is harmless there.\n- `RUN_REPLICATION_CLICKHOUSE_URL` stays clean — it goes to `@clickhouse/client` without stripping.\n\nThis works but is fragile and undiscoverable.\n\n### Suggested fix\n\nTwo independent things to address:\n\n1. **`docker/scripts/entrypoint.sh`** — only append `?secure=true` when the URL scheme is `https://`. Or, simpler: strip the param entirely before calling `goose` and translate it to the scheme (`https://` → `secure=true`, `http://` → no flag). Conflating TLS choice with a query param when the scheme already encodes it is the root issue.\n\n2. **`initializeRunsReplicationInstance`** — apply the same `secure` strip that `QUERY_CLICKHOUSE_URL` got in #3204 to `RUN_REPLICATION_CLICKHOUSE_URL` (and any other URL passed to `@clickhouse/client`). Centralizing this in a helper used by all client constructors would prevent regressions.\n\n\n\n### Reproduction repo\n\n?\n\n### To reproduce\n\n### Provide environment information\n\n- **Trigger.dev version:** `v4.4.6` (self-hosted Docker, `ghcr.io/triggerdotdev/trigger.dev:v4.4.6`)\n- **Setup:** standard `hosting/docker` compose, multi-file (`webapp/docker-compose.yml` + `worker/docker-compose.yml`)\n- **ClickHouse:** `bitnamilegacy/clickhouse:latest`, HTTP only (no TLS), port 8123, local container\n- **Host:** Linux amd64\n- **Previous working version:** `v4.4.5` (same `.env`, started healthy)\n\n### Describe the bug\n\nAfter updating the image tag from `v4.4.5` to `v4.4.6` and running `docker compose pull && up -d`, the `webapp` container enters a restart loop. Two separate ClickHouse-URL handling issues block startup, related to but not fully covered by #3184 / #3204.\n\n**Issue 1 — `entrypoint.sh` appends `?secure=true` unconditionally, goose now rejects it**\n\n`docker/scripts/entrypoint.sh` constructs `GOOSE_DBSTRING` from `CLICKHOUSE_URL` and adds `?secure=true` if `secure=` isn't already in the URL — regardless of scheme. When the URL uses `http://` (no TLS), the goose ClickHouse driver in v4.4.6 fails DSN parsing:\n\n```\n+ export GOOSE_DBSTRING=http://default:***@clickhouse:8123?secure=true\n+ /usr/local/bin/goose up\n2026/05/20 10:13:56 goose run: clickhouse [dsn parse]: http with TLS specify; clickhouse [dsn parse]: http with TLS specify\n```\n\nThis appears to be a behavior change in the goose ClickHouse driver between v4.4.5 and v4.4.6 — the same DSN was tolerated by the older driver. `entrypoint.sh` exits non-zero, container restarts forever.\n\n**Issue 2 — `RUN_REPLICATION_CLICKHOUSE_URL` is NOT stripped before being passed to `@clickhouse/client`**\n\n#3204 added stripping of the `secure` query param for `QUERY_CLICKHOUSE_URL`, but `RUN_REPLICATION_CLICKHOUSE_URL` follows the same path through `@clickhouse/client@1.12.1` and doesn't get the same treatment. Workarounding Issue 1 by adding `?secure=false` to `RUN_REPLICATION_CLICKHOUSE_URL` (because the main `CLICKHOUSE_URL` workaround value is reused as the replication URL in some setups) triggers:\n\n```\n🗃️ Runs replication service enabled\n{\"url\":\"http://default:redacted@clickhouse:8123/?secure=false\", ...}\nError: Unknown URL parameters: secure\n at loadConfigOptionsFromURL (.../config.js:267:19)\n at prepareConfigWithURL (.../config.js:42:34)\n at new ClickHouseClient (.../client.js:59:65)\n at createClient (.../@clickhouse+client@1.12.1/.../client.js:15:12)\n at new ClickhouseClient (.../webapp/build/index.js:49830:243)\n at new ClickHouse (.../webapp/build/index.js:63805:21)\n at initializeRunsReplicationInstance (.../webapp/build/index.js:190055:20)\n```\n\n### To reproduce\n\n1. Self-host `v4.4.5` with HTTP ClickHouse (no TLS), `CLICKHOUSE_URL=http://...@clickhouse:8123`, healthy.\n2. Bump `TRIGGER_IMAGE_TAG` to `v4.4.6`, `docker compose pull && up -d`.\n3. Observe `webapp` in restart loop, goose error in logs (Issue 1).\n4. Append `?secure=false` to `CLICKHOUSE_URL` and `RUN_REPLICATION_CLICKHOUSE_URL` — goose now passes, but webapp now crashes on Runs Replication init (Issue 2).\n\n### Workaround (currently running in production)\n\nAsymmetric values:\n\n```env\nCLICKHOUSE_URL=http://default:***@clickhouse:8123?secure=false\nRUN_REPLICATION_CLICKHOUSE_URL=http://default:***@clickhouse:8123\n```\n\n- `CLICKHOUSE_URL` ends with `?secure=false` so `entrypoint.sh`'s `grep -q secure=` matches and skips appending `?secure=true`. goose accepts `secure=false` + `http://` (no conflict). Webapp's own `CLICKHOUSE_URL` consumption already strips `secure` via #3204, so the param is harmless there.\n- `RUN_REPLICATION_CLICKHOUSE_URL` stays clean — it goes to `@clickhouse/client` without stripping.\n\nThis works but is fragile and undiscoverable.\n\n### Suggested fix\n\nTwo independent things to address:\n\n1. **`docker/scripts/entrypoint.sh`** — only append `?secure=true` when the URL scheme is `https://`. Or, simpler: strip the param entirely before calling `goose` and translate it to the scheme (`https://` → `secure=true`, `http://` → no flag). Conflating TLS choice with a query param when the scheme already encodes it is the root issue.\n\n2. **`initializeRunsReplicationInstance`** — apply the same `secure` strip that `QUERY_CLICKHOUSE_URL` got in #3204 to `RUN_REPLICATION_CLICKHOUSE_URL` (and any other URL passed to `@clickhouse/client`). Centralizing this in a helper used by all client constructors would prevent regressions.\n\n\n\n### Additional information\n\n_No response_","author":{"url":"https://github.com/Valentyn-Kubrak","@type":"Person","name":"Valentyn-Kubrak"},"datePublished":"2026-05-20T10:33:00Z","url":"https://github.com/triggerdotdev/trigger.dev/issues/3674"}
| react-profiling | 0 |
| react-import-map | react,react-dom,react-dom/client,react-dom/profiling,react-is,react-reconciler,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@d5750093facf |
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:c346d51c-ecf8-b43c-f663-b03391316735 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | 8D6E:1FE80C:2FE6AF7:43F5243:6AFAE9E0 |
| html-safe-nonce | e1a94fb1c52b8322e18d50f8de81a3efa089b8f29d8f942d95317cf80aa462bf |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiI4RDZFOjFGRTgwQzoyRkU2QUY3OjQzRjUyNDM6NkFGQUU5RTAiLCJ2aXNpdG9yX2lkIjoiODQ4NDE2MjE4MjM4NzU1NTIiLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ== |
| visitor-hmac | 15e2fc5fffba170b1511c7864a6ef1ada0ea39e7ec762e7f92d62efc8c34e668 |
| hovercard-subject-tag | issue:4485523456 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/triggerdotdev/trigger.dev/3674/issue_layout |
| twitter:image | https://opengraph.githubassets.com/2f55497318810d2bcff08ab92a2834cc6da7d44f6aa65b29593d293ff837f9ae/triggerdotdev/trigger.dev/issues/3674 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/2f55497318810d2bcff08ab92a2834cc6da7d44f6aa65b29593d293ff837f9ae/triggerdotdev/trigger.dev/issues/3674 |
| og:image:alt | Provide environment information Provide environment information Trigger.dev version: v4.4.6 (self-hosted Docker, ghcr.io/triggerdotdev/trigger.dev:v4.4.6) Setup: standard hosting/docker compose, mu... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | Valentyn-Kubrak |
| hostname | github.com |
| expected-hostname | github.com |
| None | 0178036d8230524a18422872393ab7e708443ae4c2047f758560a2db870c1913 |
| turbo-cache-control | no-preview |
| go-import | github.com/triggerdotdev/trigger.dev git https://github.com/triggerdotdev/trigger.dev.git |
| octolytics-dimension-user_id | 95297378 |
| octolytics-dimension-user_login | triggerdotdev |
| octolytics-dimension-repository_id | 572570113 |
| octolytics-dimension-repository_nwo | triggerdotdev/trigger.dev |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 572570113 |
| octolytics-dimension-repository_network_root_nwo | triggerdotdev/trigger.dev |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 12fff95459b24b0f882a66698ee6a36a5934d247 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
| react-app-name | issues |
Links:
Viewport: width=device-width