@@ -5,18 +5,19 @@ FROM base AS deps
5
5
# Check https://github.com/nodejs/docker-node/tree/b4117f9333da4138b03a546ec926ef50a31506c3#nodealpine to understand why libc6-compat might be needed.
6
6
RUN apk add --no-cache libc6-compat
7
7
WORKDIR /app
8
- COPY package.json pnpm-lock.yaml patches ./
8
+ COPY package.json pnpm-lock.yaml ./
9
+ COPY patches ./patches/
9
10
10
11
# Whether to skip TSC and Eslint Checks
11
12
ARG SKIP_CHECKS
12
13
ENV SKIP_CHECKS=${SKIP_CHECKS:-0}
13
14
RUN echo "SKIP_CHECKS=${SKIP_CHECKS}"
14
15
15
16
16
- RUN if $SKIP_CHECKS; then pnpm fetch --prod; else pnpm fetch; fi
17
- RUN if $SKIP_CHECKS; \
18
- then pnpm i -P --frozen-lockfile --offline -- ignore-scripts; \
19
- else pnpm i --frozen-lockfile --offline -- ignore-scripts; fi
17
+ RUN if [ " $SKIP_CHECKS" = "1" ] ; then pnpm fetch --prod; else pnpm fetch; fi
18
+ RUN if [ " $SKIP_CHECKS" = "1" ] ; \
19
+ then pnpm i -P --ignore-scripts; \
20
+ else pnpm i --ignore-scripts; fi
20
21
21
22
# If using npm with a `package-lock.json` comment out above and use below instead
22
23
# COPY package.json package-lock.json ./
@@ -29,7 +30,7 @@ COPY --from=deps /app/node_modules ./node_modules
29
30
COPY . .
30
31
31
32
# Disable anonymous Next.js telemetry data...
32
- ENV NEXT_TELEMETRY_DISABLED 1
33
+ ENV NEXT_TELEMETRY_DISABLED= 1
33
34
34
35
# Expose an optional GitHub SHA build argument.
35
36
# This is used to personalise the build.
@@ -50,9 +51,9 @@ RUN echo "GIT_SHA=${GIT_SHA}" && npm run build
50
51
FROM base AS runner
51
52
WORKDIR /app
52
53
53
- ENV NODE_ENV production
54
+ ENV NODE_ENV= production
54
55
# Uncomment the following line in case you want to disable telemetry during runtime.
55
- # ENV NEXT_TELEMETRY_DISABLED 1
56
+ # ENV NEXT_TELEMETRY_DISABLED= 1
56
57
57
58
RUN addgroup --system --gid 1001 nodejs
58
59
RUN adduser --system --uid 1001 nextjs
@@ -71,6 +72,6 @@ USER nextjs
71
72
72
73
EXPOSE 3000
73
74
74
- ENV PORT 3000
75
+ ENV PORT= 3000
75
76
76
77
CMD ["node" , "server.js" ]
0 commit comments