diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 4450c01a894a1f0f4f582edb67019753499d9332..c6a49b66d582222647faf3ed7a66cae71769b893 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -1,20 +1,28 @@ +image: node:alpine # Much smaller than other variants, faster and more resource effective + stages: - - install - - build + - install_dependencies + - lint + - build_project cache: + key: "${CI_COMMIT_REF_SLUG}" # Branch-specific cache keys to have separate caches across branches. paths: - node_modules/ - key: "$CI_BUILD_REF_NAME" # Separate cache for each branch install_dependencies: - stage: install - image: node:latest + stage: install_dependencies script: - npm install +lint: + stage: lint + script: + - npm run lint + allow_failure: true + build_project: - stage: build - image: node:latest + stage: build_project script: - - npm run build \ No newline at end of file + - npm run build +