Skip to content

fix(ui): update node to v20#15717

Merged
paulpopus merged 2 commits into
payloadcms:mainfrom
ab192130:patch-1
Apr 2, 2026
Merged

fix(ui): update node to v20#15717
paulpopus merged 2 commits into
payloadcms:mainfrom
ab192130:patch-1

Conversation

@ab192130

Copy link
Copy Markdown
Contributor

What?

Updated the Docker Node.js image version from 18-alpine to 20-alpine in the docker-compose.yml file.

Why?

Next.js 15 and Payload CMS 3 require a more recent Node.js runtime. Node.js 18 lacks the global File object, which leads to a ReferenceError: File is not defined during Server-Side Rendering (SSR). Upgrading to Node.js 20+ provides native support for the global File API, resolving this runtime crash.

How?

Modified the image property under the payload service in docker-compose.yml to use node:20-alpine.

- upgrade node image to 20-alpine to support global File object
- resolve ReferenceError: File is not defined in Next.js 15 SSR
@ab192130 ab192130 changed the title fix(docker): update node to v20 fix(ui): update node to v20 Feb 22, 2026
@github-actions github-actions Bot added the stale label Mar 28, 2026
@paulpopus paulpopus merged commit b2593d6 into payloadcms:main Apr 2, 2026
21 checks passed
@github-actions

github-actions Bot commented Apr 8, 2026

Copy link
Copy Markdown
Contributor

🚀 This is included in version v3.82.0

milamer pushed a commit to milamer/payload that referenced this pull request Apr 20, 2026
### What?
Updated the Docker Node.js image version from `18-alpine` to `20-alpine`
in the `docker-compose.yml` file.

### Why?
Next.js 15 and Payload CMS 3 require a more recent Node.js runtime.
Node.js 18 lacks the global `File` object, which leads to a
`ReferenceError: File is not defined` during Server-Side Rendering
(SSR). Upgrading to Node.js 20+ provides native support for the global
File API, resolving this runtime crash.

### How?
Modified the `image` property under the `payload` service in
`docker-compose.yml` to use `node:20-alpine`.

Co-authored-by: Paul Popus <paul@payloadcms.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants