Commit e450f238 authored by Richard Crosby's avatar Richard Crosby

chore: update how sentry releases work

parent f72efd63
Pipeline #24169 passed with stages
in 22 seconds
sentry_release_production:
stage: post-deploy
# For all available config values, check https://docs.sentry.io/cli/configuration/#configuration-values
variables:
BBK_RUNTIME_ENVIRONMENT: production
SENTRY_AUTH_TOKEN: ${SENTRY_AUTH_TOKEN}
SENTRY_ORG: brickblock
SENTRY_PROJECT: ${CI_PROJECT_NAME}
dependencies:
- build
script:
# There is no cache available in production pipelines to download `node_modules`. Thus, we have to install as first step
- yarn install
- yarn build
- yarn add --dev @sentry/cli
- yarn sentry-cli releases new "$CI_COMMIT_TAG"
- yarn sentry-cli releases files "$CI_COMMIT_TAG" upload-sourcemaps --rewrite ./build
- yarn sentry-cli releases set-commits --auto "$CI_COMMIT_TAG"
- yarn sentry-cli releases finalize "$CI_COMMIT_TAG"
- yarn sentry-cli releases deploys "$CI_COMMIT_TAG" new -e "$BBK_RUNTIME_ENVIRONMENT"
- npx @sentry/cli releases new "$CI_COMMIT_TAG"
- npx @sentry/cli releases files "$CI_COMMIT_TAG" upload-sourcemaps --rewrite ./build
- npx @sentry/cli releases set-commits --auto "$CI_COMMIT_TAG"
- npx @sentry/cli releases finalize "$CI_COMMIT_TAG"
- npx @sentry/cli releases deploys "$CI_COMMIT_TAG" new -e "$BBK_RUNTIME_ENVIRONMENT"
only:
- tags
sentry_release_staging:
stage: post-deploy
# For all available config values, check https://docs.sentry.io/cli/configuration/#configuration-values
variables:
BBK_RUNTIME_ENVIRONMENT: staging
SENTRY_AUTH_TOKEN: ${SENTRY_AUTH_TOKEN}
SENTRY_ORG: brickblock
SENTRY_PROJECT: ${CI_PROJECT_NAME}
extends: .cache-pull-only
dependencies:
- build
script:
- yarn build
- yarn add --dev @sentry/cli
- yarn sentry-cli releases new "$CI_COMMIT_SHORT_SHA"
- yarn sentry-cli releases files "$CI_COMMIT_SHORT_SHA" upload-sourcemaps --rewrite ./build
- yarn sentry-cli releases set-commits --auto "$CI_COMMIT_SHORT_SHA"
- yarn sentry-cli releases finalize "$CI_COMMIT_SHORT_SHA"
- yarn sentry-cli releases deploys "$CI_COMMIT_SHORT_SHA" new -e "$BBK_RUNTIME_ENVIRONMENT"
- npx @sentry/cli releases new "$CI_COMMIT_SHORT_SHA"
- npx @sentry/cli releases files "$CI_COMMIT_SHORT_SHA" upload-sourcemaps --rewrite ./build
- npx @sentry/cli releases set-commits --auto "$CI_COMMIT_SHORT_SHA"
- npx @sentry/cli releases finalize "$CI_COMMIT_SHORT_SHA"
- npx @sentry/cli releases deploys "$CI_COMMIT_SHORT_SHA" new -e "$BBK_RUNTIME_ENVIRONMENT"
only:
- master
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment