Skip to content

Commit

Permalink
Create workflow for sentry sourceMaps (#2311)
Browse files Browse the repository at this point in the history
* Create workflow for sentry sourceMaps

* Update main.yml
  • Loading branch information
adonispuente authored Dec 19, 2024
1 parent e984fa1 commit c7bbcad
Showing 1 changed file with 43 additions and 0 deletions.
43 changes: 43 additions & 0 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
name: sentryConfig

on:
workflow_dispatch:
inputs:
commit_hash:
description: 'The commit hash (or branch/tag) to build'
required: true
default: 'master'

jobs:
createSentryRelease:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v3
with:
ref: ${{ github.event.inputs.commit_hash }}

- name: Install dependencies
env:
SENTRY_RELEASE: compliance-${{ github.event.inputs.commit_hash }}
run: npm ci

- name: Build
env:
SENTRY_RELEASE: compliance-${{ github.event.inputs.commit_hash }}
SENTRY_AUTH_TOKEN: ${{ secrets.SENTRY_AUTH_TOKEN }}
SENTRY_ORG: ${{ secrets.SENTRY_ORG }}
SENTRY_PROJECT: ${{ secrets.SENTRY_PROJECT }}
run: npm run build --if-present

- name: Create a Sentry.io release
uses: getsentry/action-release@v1
env:
SENTRY_AUTH_TOKEN: ${{ secrets.SENTRY_AUTH_TOKEN }}
SENTRY_ORG: ${{ secrets.SENTRY_ORG }}
SENTRY_PROJECT: ${{ secrets.SENTRY_PROJECT }}
with:
tagName: ${{ github.event.inputs.commit_hash }}
releaseNamePrefix: compliance
environment: master
sourcemaps: 'dist/sourcemaps'

0 comments on commit c7bbcad

Please sign in to comment.