use node:alpine, but cache node modules [skip-ci]
This commit is contained in:
parent
85e272e923
commit
c370aed900
@ -17,16 +17,25 @@ stages:
|
||||
########
|
||||
# BUILD
|
||||
#################################################################
|
||||
|
||||
#build_fe:
|
||||
# image: node:alpine
|
||||
# script:
|
||||
# - echo ''
|
||||
# extends:
|
||||
# - .build
|
||||
.build:
|
||||
stage: build
|
||||
|
||||
build_fe:
|
||||
image: node:alpine
|
||||
script:
|
||||
- cd ./frontend
|
||||
- npm install
|
||||
cache:
|
||||
key: $CI_COMMIT_REF_SLUG-$CI_PROJECT_DIR
|
||||
paths:
|
||||
- node_modules/
|
||||
only:
|
||||
changes:
|
||||
- package-lock.json
|
||||
extends:
|
||||
- .build
|
||||
|
||||
|
||||
build_be:
|
||||
before_script:
|
||||
- apt-get update
|
||||
@ -56,8 +65,16 @@ lint_fe:
|
||||
extends:
|
||||
- .lint
|
||||
- .angular-image
|
||||
# needs:
|
||||
# - build_fe
|
||||
cache:
|
||||
key: $CI_COMMIT_REF_SLUG-$CI_PROJECT_DIR
|
||||
paths:
|
||||
- node_modules/
|
||||
policy: pull-push
|
||||
only:
|
||||
changes:
|
||||
- package-lock.json
|
||||
needs:
|
||||
- build_fe
|
||||
|
||||
#lint_be:
|
||||
# script:
|
||||
@ -78,6 +95,11 @@ test_fe:
|
||||
- cd ./frontend
|
||||
- npm update
|
||||
- ng test
|
||||
cache:
|
||||
key: $CI_COMMIT_REF_SLUG-$CI_PROJECT_DIR
|
||||
paths:
|
||||
- node_modules/
|
||||
policy: pull
|
||||
extends:
|
||||
- .test
|
||||
- .angular-image
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user