Merge pull request #216 from trezor/gitlab/deploy-stage

Gitlab deploy stage(beta, stable) in one click
pull/219/head 1.0.0-beta
Vladimir Volek 6 years ago committed by GitHub
commit 059a3b9dd9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -4,9 +4,6 @@ cache:
paths: paths:
- node_modules - node_modules
before_script:
- yarn install
stages: stages:
- test - test
- build - build
@ -15,6 +12,7 @@ stages:
lint: lint:
stage: test stage: test
script: script:
- yarn install
- yarn run lint - yarn run lint
flow: flow:
@ -25,36 +23,40 @@ flow:
unit: unit:
stage: test stage: test
script: script:
- yarn install
- yarn run test - yarn run test
build development: build development:
stage: build stage: build
script: script:
- yarn install
- yarn run build:dev - yarn run build:dev
artifacts: artifacts:
expire_in: 1 month expire_in: 1 week
paths: paths:
- build/dev - build/dev
build beta: build beta:
stage: build stage: build
script: script:
- yarn install
- yarn run build:beta - yarn run build:beta
when: manual
artifacts: artifacts:
expire_in: 1 month expire_in: 1 week
paths: paths:
- build/beta - build/beta
- scripts/s3sync.sh
build production: build stable:
stage: build stage: build
script: script:
- yarn install
- yarn run build:stable - yarn run build:stable
when: manual
artifacts: artifacts:
expire_in: 1 month expire_in: 1 week
paths: paths:
- build/stable - build/stable
- scripts/s3sync.sh
deploy review: deploy review:
stage: deploy stage: deploy
@ -73,3 +75,35 @@ deploy review:
- branches - branches
tags: tags:
- deploy - deploy
deploy stage beta:
stage: deploy
variables:
GIT_STRATEGY: none
AWS_ACCESS_KEY_ID: $STAGE_AWS_ACCESS_KEY_ID
AWS_SECRET_ACCESS_KEY: $STAGE_AWS_SECRET_ACCESS_KEY
when: manual
dependencies:
- build beta
script:
- scripts/s3sync.sh stage beta
only:
- beta
tags:
- deploy
deploy stage stable:
stage: deploy
variables:
GIT_STRATEGY: none
AWS_ACCESS_KEY_ID: $STAGE_AWS_ACCESS_KEY_ID
AWS_SECRET_ACCESS_KEY: $STAGE_AWS_SECRET_ACCESS_KEY
when: manual
dependencies:
- build stable
script:
- scripts/s3sync.sh stage stable
only:
- stable
tags:
- deploy

Loading…
Cancel
Save