You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is your feature request related to a problem? Please describe.
We self-host Trigger.dev inside a FedRAMP boundary. FedRAMP (NIST SC-13) requires the task runtime to use a FIPS-validated cryptographic module. Stock Node statically links OpenSSL and can't run in FIPS mode, so this has to be a property of the base image (e.g. Chainguard node-fips).
The deploy image base can't be changed today:
The base and build images are hard-pinned per runtime in BASE_IMAGE and BUILD_IMAGE.
Also accept the same values from build-time env vars, e.g. TRIGGER_BUILD_BASE_IMAGE / TRIGGER_BUILD_BUILD_IMAGE (with the same precedence as the TRIGGER_BUILD_SKIP_APT_SNAPSHOT escape hatch proposed in #4558). Then a platform team can set the base once in CI for every project instead of in each project's config.
In generateContainerfile: baseImage: env.TRIGGER_BUILD_BASE_IMAGE ?? config.build.image?.base ?? BASE_IMAGE[runtime], and the same pattern for BUILD_IMAGE. Nothing changes when neither is set.
The override has to live on the CLI side. The Containerfile is generated and built during trigger deploy, and the supervisor only runs the digest it's given, so the webapp and Helm chart have nothing to hook into.
Document the contract the generated Containerfile already relies on, plus a "you own this image" caveat:
A node user, because the final stage runs USER node.
glibc, for native modules built in the build stage.
image.pkgs, and the extensions that emit apt-get (aptGet, playwright, …), assume Debian. When a custom base is set, the CLI should either reject them with a clear error or leave package installation to the image owner.
Describe alternate solutions
yarn patch the BASE_IMAGE constant (what we do today). It works, but every CLI bump needs re-validation, and the digest bumps need their own automation.
Rebase or rewrite the image after push. Doesn't work: finalize records the digest before anything could change it.
Swap the base with image.instructions. Doesn't work: instructions run inside FROM base and can't change what base is.
Let users supply the whole Containerfile (raised as an alternative in feat: Allow injecting ca cert in project #1210). This is far more surface area than a base override, and it would break whenever the generated stages change.
No existing issue covers this. We searched for base image, custom image, Containerfile, FIPS, hardened and Chainguard.
Possible follow-up (not part of this request): an instance-level policy, set through webapp env / Helm values, that pins or allow-lists the base images deploys to that instance may use, enforced when the deploy is created. That would make "every task image on this instance is FIPS" provable from the server side, not only by CI convention.
This applies to any regulated self-hoster (FedRAMP, DoD IL, HIPAA/PCI hardening, internal golden images), not just FIPS.
Happy to contribute the PR. It looks like one config field plus a two-line fallback in buildImage.ts, plus docs.
Is your feature request related to a problem? Please describe.
We self-host Trigger.dev inside a FedRAMP boundary. FedRAMP (NIST SC-13) requires the task runtime to use a FIPS-validated cryptographic module. Stock Node statically links OpenSSL and can't run in FIPS mode, so this has to be a property of the base image (e.g. Chainguard
node-fips).The deploy image base can't be changed today:
BASE_IMAGEandBUILD_IMAGE.FROM base AS final.image.instructions/image.pkgs, but they can't replace it.The only option today is to
yarn patchtheBASE_IMAGEconstant in the CLI. That has to be redone on every CLI release.Describe the solution you'd like to see
An opt-in override in
trigger.config.ts, next tobuild.extensions:Also accept the same values from build-time env vars, e.g.
TRIGGER_BUILD_BASE_IMAGE/TRIGGER_BUILD_BUILD_IMAGE(with the same precedence as theTRIGGER_BUILD_SKIP_APT_SNAPSHOTescape hatch proposed in #4558). Then a platform team can set the base once in CI for every project instead of in each project's config.In
generateContainerfile:baseImage: env.TRIGGER_BUILD_BASE_IMAGE ?? config.build.image?.base ?? BASE_IMAGE[runtime], and the same pattern forBUILD_IMAGE. Nothing changes when neither is set.The override has to live on the CLI side. The Containerfile is generated and built during
trigger deploy, and the supervisor only runs the digest it's given, so the webapp and Helm chart have nothing to hook into.Document the contract the generated Containerfile already relies on, plus a "you own this image" caveat:
nodeonPATHat the runtime's major version.DEFAULT_PACKAGES:busybox,ca-certificates,dumb-init(the entrypoint),git,openssl.nodeuser, because the final stage runsUSER node.image.pkgs, and the extensions that emitapt-get(aptGet,playwright, …), assume Debian. When a custom base is set, the CLI should either reject them with a clear error or leave package installation to the image owner.Describe alternate solutions
yarn patchtheBASE_IMAGEconstant (what we do today). It works, but every CLI bump needs re-validation, and the digest bumps need their own automation.image.instructions. Doesn't work: instructions run insideFROM baseand can't change whatbaseis.Additional information
buildImage.ts, plus docs.