From fbb9fd1c374b2ce87e74413e15da19a5faadca81 Mon Sep 17 00:00:00 2001 From: Iqro-dev Date: Fri, 27 Dec 2024 19:08:18 +0100 Subject: [PATCH] refactor(docker): use bitnami --- Dockerfile | 8 +++++--- package.json | 2 +- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/Dockerfile b/Dockerfile index 3e40e230..054c615a 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,17 +1,18 @@ -FROM node:20.12.2-debian as development +FROM bitnami/node:20.12.2 AS development WORKDIR /usr/src/app COPY package.json ./ COPY pnpm-lock.yaml ./ +RUN npm install -g pnpm RUN pnpm install COPY . . RUN pnpm run build -FROM node:20.12.2-debian as production +FROM bitnami/node:20.12.2 AS production ARG NODE_ENV=production ARG EnvironmentVariable @@ -22,7 +23,8 @@ WORKDIR /usr/src/app COPY package.json ./ COPY pnpm-lock.yaml ./ -RUN pnpm install --production --ignore-scripts +RUN npm install -g pnpm +RUN pnpm install --production --ignore-scripts RUN npm install pm2 -g COPY . . diff --git a/package.json b/package.json index ca04951f..d18402ce 100644 --- a/package.json +++ b/package.json @@ -11,7 +11,7 @@ "bun": "please-use-pnpm", "pnpm": ">=9" }, - "packageManager": "pnpm@9.14.2", +"packageManager": "pnpm@9.0.1", "scripts": { "prebuild": "rimraf dist", "build": "nest build",