Skip to content

Commit

Permalink
🚑 hotfix: alpine에서 openssl, prisma 오류
Browse files Browse the repository at this point in the history
  • Loading branch information
kms0219kms committed Dec 27, 2024
1 parent 1e97384 commit e0e4111
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 8 deletions.
18 changes: 11 additions & 7 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,16 +1,20 @@
FROM node:20-alpine
FROM node:22-alpine3.19 AS base

WORKDIR /usr/src/app
COPY . .

COPY package.json ./
COPY yarn.lock ./
FROM base AS prod-deps
RUN apk add --no-cache git
RUN yarn install --prod --frozen-lockfile

FROM base AS build
RUN apk add --no-cache git
RUN yarn install --frozen-lockfile

COPY . .

RUN yarn build

FROM base
COPY --from=prod-deps /usr/src/app/node_modules /usr/src/app/node_modules
COPY --from=build /usr/src/app/dist /usr/src/app/dist

EXPOSE 3000
CMD [ "node", "dist/main.js" ]
CMD [ "node", "dist/main.js" ]
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
"private": true,
"license": "UNLICENSED",
"scripts": {
"build": "prisma generate & nest build",
"build": "prisma generate && nest build",
"format": "prettier --write \"src/**/*.ts\" \"test/**/*.ts\"",
"start": "nest start",
"start:dev": "nest start --watch",
Expand Down

0 comments on commit e0e4111

Please sign in to comment.