Skip to content
Snippets Groups Projects
.gitlab-ci.yml 514 B
image: node:alpine # Much smaller than other variants, faster and more resource effective

stages:
  - install_dependencies
  - lint
  - build_project

cache:
  key: "${CI_COMMIT_REF_SLUG}" # Branch-specific cache keys to have separate caches across branches.
  paths:
    - node_modules/

install_dependencies:
  stage: install_dependencies
  script:
    - npm install

lint:
  stage: lint
  script:
    - npm run lint
  allow_failure: true  

build_project:
  stage: build_project
  script:
    - npm run build