ci: use cache instead of artifacts for node modules

This commit is contained in:
Jovan Krunić
2019-04-26 15:17:18 +02:00
parent 371dbc2890
commit b9a95313cd

View File

@@ -1,5 +1,13 @@
image: registry.gitlab.com/openstapps/app
cache:
key: ${CI_COMMIT_REF_SLUG}
paths:
- node_modules
before_script:
- npm install
stages:
- setup
- build
@@ -20,6 +28,8 @@ setup:
- docker login -u gitlab-ci-token -p $CI_BUILD_TOKEN registry.gitlab.com
- docker build -t registry.gitlab.com/openstapps/app .
- docker push registry.gitlab.com/openstapps/app
cache: {} # disable irrelevant cache for this job
before_script: [] # do not run irrelevant before script for this job
tags:
- docker
@@ -30,7 +40,6 @@ build:
- npm run build
artifacts:
paths:
- node_modules
- www
unit: