Skip to content

Commit c2a7629

Browse files
docs(webapp): warn that DEPLOY_IMAGE_OVERRIDE is single-tenant only
No behavior change. Adds a strong warning to env.server.ts docstring + changeset entry explaining the foot-gun for multi-tenant installs. Co-authored-by: Cursor <cursoragent@cursor.com>
1 parent c4ec54e commit c2a7629

2 files changed

Lines changed: 26 additions & 6 deletions

File tree

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
---
2+
"trigger.dev": minor
3+
---
4+
5+
webapp: clarify DEPLOY_IMAGE_OVERRIDE is single-tenant only
6+
7+
The `DEPLOY_IMAGE_OVERRIDE` env var forces every deployment finalized by the webapp to use the configured image, ignoring the registry config / per-deployment image computation. Useful for self-hosted single-tenant installs where CI builds one canonical tasks image; dangerous on cloud / multi-tenant where deployments come from untrusted user code. No behavior change — just adds a strong warning docstring to `apps/webapp/app/env.server.ts` calling out the multi-tenant foot-gun.

apps/webapp/app/env.server.ts

Lines changed: 19 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -434,15 +434,28 @@ const EnvironmentSchema = z
434434

435435
DEPLOY_IMAGE_PLATFORM: z.string().default("linux/amd64"),
436436
/**
437-
* Full image reference override - bypasses auto-generation of image tags.
438-
* When set, every deployment uses this exact image reference instead of
437+
* DEPLOY_IMAGE_OVERRIDE — full image reference override; bypasses
438+
* auto-generation of image tags. When set, every deployment finalized
439+
* by this webapp instance uses this exact image reference instead of
439440
* being routed through `getDeploymentImageRef` (ECR repo creation,
440441
* per-project tagging, isEcr/repoCreated detection, etc).
441442
*
442-
* Intended for self-hosted setups where images are produced by a separate
443-
* pipeline (e.g. CI builds + signs the image, the webapp just references
444-
* it). Should NOT be set in multi-tenant deployments because every project
445-
* shares the same image digest.
443+
* ⚠️ WARNING: SINGLE-TENANT ONLY. ⚠️
444+
*
445+
* When set, every deployment finalized by this webapp instance will be
446+
* wired to this image, regardless of which org / project triggered it.
447+
* This is a foot-gun for any multi-tenant trigger.dev install
448+
* (including Cloud) where deployments come from untrusted user code:
449+
* one operator-set value silently overrides every tenant's per-project
450+
* image. Only enable when BOTH of the following hold:
451+
* - You control the build pipeline producing the image (e.g. your CI
452+
* builds + pushes a single canonical tasks image per release), AND
453+
* - The install serves only your own org's projects (self-hosted,
454+
* single-tenant).
455+
*
456+
* For cloud / multi-tenant: leave unset. The deployment image is
457+
* normally computed per-deployment from the registry config and the
458+
* deploy version, which keeps tenants isolated.
446459
*
447460
* Empty string is treated as unset.
448461
*

0 commit comments

Comments
 (0)