diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 18d2bd51be0a5bf33320d0bf2fc771adb8b4433f..79117ead1c8d35b1a75b19b9c615d26f748d0479 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -1,12 +1,33 @@ -image: alpine:latest +image: node:14.15.4 +cache: + untracked: true + key: "$CI_BUILD_REF_NAME" + paths: + - node_modules/ -pages: - stage: deploy +stages: + - install + - unit-testing + - deploy-pages + +install: + stage: install + script: + - npm install + - npm install --only=dev + +unit_testing: + stage: unit-testing + script: + - npm run test + +deploy_pages: + image: alpine:latest + stage: deploy-pages script: - - echo 'Nothing to do...' + - echo 'Deploying...' artifacts: paths: - public - expire_in: 1 day only: - master