Skip to content

Commit 623d6ff

Browse files
author
Peter Bengtsson
authored
no need to check typescript in dockerfile (#22754)
* no need to check TypeScript in Dockerfile Part of #1158 * refactor how the port is set
1 parent 04d2138 commit 623d6ff

1 file changed

Lines changed: 4 additions & 5 deletions

File tree

Dockerfile

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -50,8 +50,6 @@ COPY next.config.js ./next.config.js
5050
COPY tsconfig.json ./tsconfig.json
5151
COPY next-env.d.ts ./next-env.d.ts
5252

53-
RUN npx tsc --noEmit
54-
5553
RUN npm run build
5654

5755
# --------------------------------------------------------------------------------
@@ -94,9 +92,10 @@ COPY --chown=node:node package*.json ./
9492
COPY --chown=node:node feature-flags.json ./
9593
COPY --chown=node:node next.config.js ./
9694

97-
EXPOSE 80
98-
EXPOSE 443
99-
EXPOSE 4000
95+
# This makes sure server.mjs always picks up the preferred port
96+
ENV PORT=4000
97+
EXPOSE $PORT
98+
10099
CMD ["node", "server.mjs"]
101100

102101

0 commit comments

Comments
 (0)