mirror of https://gitlab.com/curben/blog
ci(gitlab): move `npm install` to job script
- global script somehow doesn't work anymore
This commit is contained in:
parent
09871aa8fe
commit
755e16c5de
|
@ -4,12 +4,10 @@ cache: # add cache to 'node_modules' for speeding up builds
|
||||||
paths:
|
paths:
|
||||||
- node_modules/ # Node modules and dependencies
|
- node_modules/ # Node modules and dependencies
|
||||||
|
|
||||||
before_script:
|
|
||||||
- npm install --only=prod
|
|
||||||
|
|
||||||
test:
|
test:
|
||||||
before_script:
|
before_script:
|
||||||
- 'which ssh-agent || (apk update && apk add openssh-client git)'
|
- 'which ssh-agent || (apk update && apk add openssh-client git)'
|
||||||
|
- npm install --only=prod
|
||||||
|
|
||||||
script:
|
script:
|
||||||
- npm install --only=prod snyk && npm run snyk # Refer to "scripts" in package.json
|
- npm install --only=prod snyk && npm run snyk # Refer to "scripts" in package.json
|
||||||
|
@ -45,6 +43,9 @@ test:
|
||||||
when: always
|
when: always
|
||||||
|
|
||||||
renovate: # Check dependency update
|
renovate: # Check dependency update
|
||||||
|
before_script:
|
||||||
|
- npm install --only=prod
|
||||||
|
|
||||||
script:
|
script:
|
||||||
- npm install --only=prod renovate
|
- npm install --only=prod renovate
|
||||||
- npm run renovate
|
- npm run renovate
|
||||||
|
|
Loading…
Reference in New Issue