chore: move the website build off EOL Node onto 24 LTS (#223) - #224
Open
akshat-kumar-singhal wants to merge 1 commit into
Open
chore: move the website build off EOL Node onto 24 LTS (#223)#224akshat-kumar-singhal wants to merge 1 commit into
akshat-kumar-singhal wants to merge 1 commit into
Conversation
The Dockerfile's builder stage pinned node:23.11.1-alpine3.21. v23 is a non-LTS line that went EOL on 2025-06-01, so it receives no security patches — including for the bundled OpenSSL and undici. That stage is what actually runs `next build` for production gofr.dev: gofr-dev/gofr's docs/Dockerfile layers framework docs onto this image and builds there. CI pinned Node 18.x in all three jobs. v18 went EOL 2025-04-30. Bumped alongside so the PR check validates the same runtime that ships rather than one that is both dead and no longer used by the image. Node 24 is the active LTS through 2028-04-30. The builder tracks the major tag instead of an exact patch: this repo has no Renovate or Dependabot, and the previous exact pin is precisely how the base silently outlived its support window. Verified on node:24-alpine (v24.19.0, Yarn 1.22.22): - `yarn install --frozen-lockfile` — exit 0, no resolution drift - `docker build --target builder` and the full image — both green - next build exports 33 static files; nginx stage serves them - sharp@0.32.6 loads its native libvips (vips 8.14.5) - all three prebuild scripts run clean
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description:
Fixes #223.
Moves this repo's two Node runtimes — the Docker builder stage and CI — onto Node 24 LTS.
1.
Dockerfilebuilder stage:node:23.11.1-alpine3.21→node:24-alpinev23 is an odd-numbered line that was never LTS, and it went end-of-life on 2025-06-01. It receives no security patches, including for the bundled OpenSSL and undici.
This is not a peripheral image.
gofr-dev/gofr'sdocs/DockerfiledoesFROM ghcr.io/gofr-dev/website:${WEBSITE_TAG} AS builder, layers the framework docs on top, and runsnpm run build— so this stage is the runtime that actually performsnext buildfor productiongofr.dev, on both the prod and stage deploy paths.2.
.github/workflows/package.yml:node-version: 18.x→24.xin all three jobsv18 went EOL 2025-04-30. Included here rather than split off because leaving it would mean the PR check validates
yarn install && yarn buildon a runtime that is both unsupported and no longer the one the shipped image uses — CI would be green against something that never runs in production. Companion to gofr-dev/gofr#3871, which fixed the same pin in the deploy workflows on the framework side.Why the major tag and not another exact patch pin
The builder now tracks
node:24-alpinerather thannode:24.19.0-alpineX.Y. This repo has no Renovate or Dependabot configuration, so an exact pin has nothing to bump it — which is exactly how23.11.1came to outlive its support line unnoticed. A floating major picks up patch and Alpine security updates on every rebuild and only needs human attention when the major itself approaches EOL (2028-04-30).Happy to switch to an exact pin if you'd rather, but I'd suggest pairing that with a Renovate config.
Verification
The issue noted that
next@13.4.16andsharp@^0.32.6(native binaries) were the likeliest things to break on Node 24. Both were checked — all of the below onnode:24-alpine, Node v24.19.0, Yarn 1.22.22:yarn install --frozen-lockfiledocker build --target builder(what gofr's deploy uses)docker buildfull image (whatpackage.ymlpublishes)next buildstatic export/app/out/usr/share/nginx/html, nginx 1.27.5sharp@0.32.6native loadprebuildscripts (fetch-github-stars,generate-changelog-rss,generate-llms-full)No new warnings beyond what the build already emitted: the pre-existing unmet-peer-dependency set (
@algolia/autocomplete-*,autoprefixer/postcss,ts-api-utils), aurl.parse()DEP0169deprecation from a transitive dep, and the existing/certificateclient-rendering notice from Next.Breaking Changes (if applicable):
None. No application code, dependency, or lockfile changes —
package.jsonandyarn.lockare untouched. Build output is byte-for-byte the same set of 33 exported files.Additional Information:
package.jsondeclares noenginesfield, so nothing constrained the major.Worth flagging for a follow-up, out of scope here: this repo has no Renovate/Dependabot, which is the underlying reason both pins went stale silently rather than either one being noticed. A minimal Renovate config covering Docker base images and
actions/*would prevent a third instance of this.