From 34672c4ca776088933ad7de97f0b9bffc483c144 Mon Sep 17 00:00:00 2001 From: =?utf8?q?J=C3=A9r=C3=B4me=20Benoit?= Date: Wed, 19 Oct 2022 14:09:23 +0200 Subject: [PATCH] Fix mbt installation with previous LTS node version MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Also cleanup npm cache to minimize the image size Signed-off-by: Jérôme Benoit --- .xmake.cfg | 2 +- Dockerfile | 3 ++- Makefile | 6 +++--- 3 files changed, 6 insertions(+), 5 deletions(-) diff --git a/.xmake.cfg b/.xmake.cfg index 33d6cd1..412b278 100644 --- a/.xmake.cfg +++ b/.xmake.cfg @@ -1,5 +1,5 @@ [xmake] -version=1.0.2 +version=1.0.3 # https://github.wdf.sap.corp/pages/xmake-ci/User-Guide/Setting_up_a_Build/Release_Procedure/Release_Versions/ [buildplugin] diff --git a/Dockerfile b/Dockerfile index e772cea..fd92977 100644 --- a/Dockerfile +++ b/Dockerfile @@ -156,7 +156,8 @@ RUN set -ex \ ARG MBT_VERSION=1.2.18 RUN set -ex \ - && npm install -g mbt@${MBT_VERSION} \ + && npm install -g --unsafe-perm mbt@${MBT_VERSION} \ + && npm cache clean -g --force \ # smoke test && mbt --version diff --git a/Makefile b/Makefile index b972ac2..3d0ffc8 100644 --- a/Makefile +++ b/Makefile @@ -1,5 +1,5 @@ PROJECT_NAME?=sap-e-mobility -NAME:=mbt-docker +NAME?=mbt-docker SUBMODULES_INIT?=false DOCKER_REGISTRY_USERNAME?=fraggle0 DOCKER_REGISTRY_PASSWORD?= @@ -19,10 +19,10 @@ ifeq '$(SUBMODULES_INIT)' 'true' endif $(NAME): $(submodules-init) - docker-compose -p $(PROJECT_NAME) up -d + docker-compose -p $(PROJECT_NAME) up -d $(NAME) $(NAME)-force: $(submodules-init) - docker-compose -p $(PROJECT_NAME) up -d --build --force-recreate + docker-compose -p $(PROJECT_NAME) up -d --build --force-recreate $(NAME) all: $(NAME) -- 2.34.1