Update .gitlab-ci.yml for build fix
This commit is contained in:
parent
7223c8636d
commit
fe5b799f6d
1 changed files with 21 additions and 13 deletions
|
@ -1,19 +1,27 @@
|
|||
image: node:latest
|
||||
image: node:15.12-alpine3.13
|
||||
|
||||
# allow caching for faster deployment
|
||||
cache:
|
||||
paths:
|
||||
- node_modules/
|
||||
- public/
|
||||
- .cache/
|
||||
stages:
|
||||
- test
|
||||
- deploy
|
||||
|
||||
test:
|
||||
stage: test
|
||||
script:
|
||||
- cd website
|
||||
- yarn install
|
||||
- yarn build
|
||||
rules:
|
||||
- if: $CI_COMMIT_REF_NAME != $CI_DEFAULT_BRANCH
|
||||
|
||||
pages:
|
||||
stage: deploy
|
||||
script:
|
||||
- yarn install
|
||||
- yarn build:gitlab
|
||||
- cd website
|
||||
- yarn install
|
||||
- yarn build
|
||||
- mv ./build ../public
|
||||
artifacts:
|
||||
paths:
|
||||
- public
|
||||
only:
|
||||
- master
|
||||
paths:
|
||||
- public
|
||||
rules:
|
||||
- if: $CI_COMMIT_REF_NAME == $CI_DEFAULT_BRANCH
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue