From 6be6f6c1d83ebd4fd9cc4c96b4d20912da26b29a Mon Sep 17 00:00:00 2001 From: Vladimir Volek Date: Tue, 20 Aug 2019 14:51:43 +0200 Subject: [PATCH] migrate ci --- .gitlab-ci.yml | 56 +++++++++++--------------------------------------- 1 file changed, 12 insertions(+), 44 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 0fc29c48..22f92159 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -13,7 +13,18 @@ cache: - node_modules - ${CYPRESS_CACHE_FOLDER} +install and build: + stage: install + script: + - yarn install + artifacts: + expire_in: 2 hours + when: always + paths: + - node_modules + stages: + - install - test - build - deploy @@ -22,25 +33,21 @@ stages: lint: stage: test script: - - yarn install - yarn run lint flow: stage: test script: - - yarn install - yarn run flow unit: stage: test script: - - yarn install - yarn run test build development: stage: build script: - - yarn install - yarn run build:dev artifacts: expire_in: 1 week @@ -50,7 +57,6 @@ build development: build beta: stage: build script: - - yarn install - yarn run build:beta only: - beta @@ -63,7 +69,6 @@ build beta: build stable: stage: build script: - - yarn install - yarn run build:stable only: - stable @@ -73,22 +78,6 @@ build stable: - build/stable - scripts/s3sync.sh -# build emulator and bridge image: -# variables: -# CONTAINER_NAME: "$CI_REGISTRY/emulator-bridge-tests" -# image: docker:latest -# services: -# - docker:dind -# before_script: -# - docker login $CI_REGISTRY -u $CI_REGISTRY_USER -p $CI_REGISTRY_PASSWORD -# stage: build -# when: manual -# script: -# - docker pull $CONTAINER_NAME:latest || true -# - docker build --cache-from $CONTAINER_NAME:latest --tag $CONTAINER_NAME:$CI_COMMIT_SHA --tag $CONTAINER_NAME:latest . -# - docker push $CONTAINER_NAME:$CI_COMMIT_SHA -# - docker push $CONTAINER_NAME:latest - deploy review: stage: deploy variables: @@ -166,25 +155,4 @@ delete review: only: - branches tags: - - deploy - -# integration tests: -# image: docker:latest -# services: -# - docker:dind -# stage: integration tests -# script: -# - 'export SHARED_PATH="$(dirname ${CI_PROJECT_DIR})/shared"' -# - rm -r ${SHARED_PATH} || true -# - docker build -f Dockerfile.test -t wallet-emulator-bridge-tests . -# - mkdir -p ${SHARED_PATH}/trezor-wallet/screenshots -# - mkdir -p ${SHARED_PATH}/trezor-wallet/videos -# - docker run --volume ${SHARED_PATH}/trezor-wallet/screenshots:/trezor-wallet/test/screenshots --volume ${SHARED_PATH}/trezor-wallet/videos:/trezor-wallet/test/videos --rm wallet-emulator-bridge-tests -# - find ${SHARED_PATH} -# - mkdir trezor-wallet -# - cp -r ${SHARED_PATH}/ trezor-wallet/ -# artifacts: -# when: always -# expire_in: 1 week -# paths: -# - trezor-wallet/ + - deploy \ No newline at end of file