From 80f01daba89d96a8f55bd6164e51fc9f7a1fd2cb Mon Sep 17 00:00:00 2001 From: Jorenn92 Date: Mon, 8 Jan 2024 16:34:33 +0100 Subject: [PATCH] refactor: add sharp package before running build --- Dockerfile | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/Dockerfile b/Dockerfile index b12a46e7..7d94e3d1 100644 --- a/Dockerfile +++ b/Dockerfile @@ -26,6 +26,12 @@ RUN yarn global add @nestjs/cli --network-timeout 99999999 && \ yarn config set python /usr/bin/python3 && \ yarn --force --non-interactive --frozen-lockfile --network-timeout 99999999 +RUN \ +case "${TARGETPLATFORM}" in ('linux/arm64' | 'linux/amd64') \ +yarn add --save --network-timeout 99999999 sharp \ +;; \ +esac + RUN yarn run build:server RUN yarn run build:ui @@ -33,12 +39,6 @@ RUN yarn run build:ui RUN yarn run docs-generate && \ rm -rf ./docs -RUN \ - case "${TARGETPLATFORM}" in ('linux/arm64' | 'linux/amd64') \ - yarn add --save --network-timeout 99999999 sharp \ - ;; \ - esac - RUN yarn --production --non-interactive --ignore-scripts --prefer-offline --frozen-lockfile --network-timeout 99999999 FROM node:20-alpine3.19