From d9e1754ff9750ec23ed9852bb50bdaee6d8ca915 Mon Sep 17 00:00:00 2001
From: Yoan VALLET <ext.sopra.yvallet@grandlyon.com>
Date: Wed, 20 Jul 2022 13:58:51 +0200
Subject: [PATCH] fix(docker): use yarn.lock during build

---
 Dockerfile | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)

diff --git a/Dockerfile b/Dockerfile
index 0086ad46..2e64a321 100644
--- a/Dockerfile
+++ b/Dockerfile
@@ -2,10 +2,11 @@
 FROM node:14-alpine as build-stage
 
 WORKDIR /app
-COPY package*.json /app/
-RUN npm install
+COPY package.json /app/
+COPY yarn.lock /app/
+RUN yarn install
 COPY ./ /app/
-RUN npm run build
+RUN yarn build
 
 # Stage 1, based on Nginx, to have only the compiled app, ready for production with Nginx
 FROM nginx:1.16
-- 
GitLab