cache: &global_cache
key: develop
paths:
- node_modules/
stages:
- init_env
- build
- deploy
init_env:
stage: init_env
script:
- npm install
allow_failure: false
only:
refs:
- develop
- crm-debug
build:
stage: build
script:
- npm run build
artifacts:
paths:
- dist/
expire_in: 1 week
allow_failure: false
only:
refs:
- develop
build-debug:
stage: build
script:
- npm run build:no-auth
artifacts:
paths:
- dist/
expire_in: 1 week
allow_failure: false
only:
refs:
- crm-debug
deploy:
stage: deploy
script:
- npm run deploy
- sudo scp dist/index.html www@168.192.1.1:/data/web/
allow_failure: false
only:
refs:
- bussess
deploy-test:
stage: deploy
script:
- npm run deploy:test
- sudo scp dist/index.html www@168.192.1.1:/data/web/
allow_failure: false
only:
refs:
- test-branch
deploy:
stage: deploy
script:
- npm run deploy
- sudo scp dist/index.html www@168.192.1.1:/data/web/
allow_failure: false
only:
refs:
- develop
deploy-debug:
stage: deploy
script:
- npm run deploy:no-auth
- sudo cp dist/index.html /home/biv-apps/crm-debug-bi-web/
allow_failure: false
only:
refs:
- crm-debug