From 350471363e542b1e5f727aa95632e14f52d741cf Mon Sep 17 00:00:00 2001 From: lukas Date: Tue, 22 Dec 2020 17:41:54 +0100 Subject: [PATCH] new way to initialize npm packages --- .gitlab-ci.yml | 18 +++++++----------- 1 file changed, 7 insertions(+), 11 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 3b5a2fe..3827296 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -1,16 +1,19 @@ -image: node:14 +image: node:latest stages: - - prepare - build - test - packaging - deploy +# Cache modules in between jobs cache: - key: "$CI_COMMIT_REF_SLUG" # use per branch caching + key: ${CI_COMMIT_REF_SLUG} paths: - - node_modules/ + - .npm/ + +before_script: + - npm ci --cache .npm --prefer-offline include: - template: Code-Quality.gitlab-ci.yml @@ -18,11 +21,6 @@ include: variables: SAST_DISABLE_DIND: "true" -Node_dependencies: - stage: prepare - script: - - npm install --progress=false - Minimize: stage: build script: @@ -31,7 +29,6 @@ Minimize: expire_in: 7 days paths: - build/ - needs: ["Node_dependencies"] Frontend_Tests: stage: test @@ -41,7 +38,6 @@ Frontend_Tests: reports: junit: - ./junit.xml - needs: ["Node_dependencies"] code_quality: tags: