Skip to content

Commit d682b09

Browse files
committed
Update to Node 20
This should fix the memleak issue we are seeing See vercel/next.js#49929
1 parent d6f04dc commit d682b09

File tree

3 files changed

+5
-5
lines changed

3 files changed

+5
-5
lines changed

.nvmrc

+1-1
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
16
1+
20

Dockerfile

+3-3
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# Copied from https://github.com/vercel/next.js/tree/canary/examples/with-docker
22

33
# Install dependencies only when needed
4-
FROM node:16-alpine AS deps
4+
FROM node:20-alpine AS deps
55
# Check https://github.com/nodejs/docker-node/tree/b4117f9333da4138b03a546ec926ef50a31506c3#nodealpine to understand why libc6-compat might be needed.
66
RUN apk add --no-cache libc6-compat
77
WORKDIR /app
@@ -17,7 +17,7 @@ RUN \
1717

1818

1919
# Rebuild the source code only when needed
20-
FROM node:16-alpine AS builder
20+
FROM node:20-alpine AS builder
2121
WORKDIR /app
2222
COPY --from=deps /app/node_modules ./node_modules
2323
COPY . .
@@ -33,7 +33,7 @@ RUN yarn build
3333
# RUN npm run build
3434

3535
# Production image, copy all the files and run next
36-
FROM node:16-alpine AS runner
36+
FROM node:20-alpine AS runner
3737
WORKDIR /app
3838

3939
ENV NODE_ENV production

package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
"version": "0.1.0",
44
"private": true,
55
"engines": {
6-
"node": "^16.0.0"
6+
"node": "^20.0.0"
77
},
88
"scripts": {
99
"dev": "next dev",

0 commit comments

Comments
 (0)