File tree Expand file tree Collapse file tree 5 files changed +283
-2
lines changed
Expand file tree Collapse file tree 5 files changed +283
-2
lines changed Original file line number Diff line number Diff line change @@ -41,14 +41,21 @@ jobs:
4141 uses : cloudflare/wrangler-action@da0e0dfe58b7a431659754fdf3f186c529afbe65 # v3.14.1
4242 with :
4343 apiToken : ${{ secrets.CF_API_TOKEN }}
44- command : deploy --env staging
44+ command : deploy --env staging --outdir=./dist
45+
46+ - name : Upload sourcemaps for dist-worker-staging
47+ if : github.event_name == 'push'
48+ env :
49+ SENTRY_AUTH_TOKEN : ${{ secrets.SENTRY_AUTH_TOKEN }}
50+ run : |
51+ npx sentry-cli sourcemaps inject --org nodejs --project dist-worker-staging ./dist && sentry-cli sourcemaps upload --org nodejs --project dist-worker-staging ./dist
4552
4653 - name : Deploy to Production
4754 if : github.event_name == 'workflow_dispatch'
4855 uses : cloudflare/wrangler-action@da0e0dfe58b7a431659754fdf3f186c529afbe65 # v3.14.1
4956 with :
5057 apiToken : ${{ secrets.CF_API_TOKEN }}
51- command : deploy --env prod
58+ command : deploy --env prod --outdir=./dist
5259
5360 - name : Alert on Failure
5461 if : failure() && github.repository == 'nodejs/release-cloudflare-worker'
Original file line number Diff line number Diff line change @@ -2,3 +2,4 @@ node_modules/
22.wrangler /
33dist /
44.dev.vars
5+ .sentryclirc
Original file line number Diff line number Diff line change 1818 "@eslint/eslintrc" : " ^3.2.0" ,
1919 "@eslint/js" : " ^9.32.0" ,
2020 "@reporters/github" : " ^1.7.2" ,
21+ "@sentry/cli" : " ^2.54.0" ,
2122 "@types/mustache" : " ^4.2.6" ,
2223 "@types/node" : " ^24.3.0" ,
2324 "@typescript-eslint/eslint-plugin" : " ^8.41.0" ,
Original file line number Diff line number Diff line change @@ -45,6 +45,13 @@ export default {
4545 execution : ctx ,
4646 } ;
4747
48+ if (
49+ env . ENVIRONMENT === 'staging' &&
50+ request . url === '/_657ee98d-f9d3-46cd-837b-f58a88add70a'
51+ ) {
52+ throw new Error ( 'sentry source map testing' ) ;
53+ }
54+
4855 return await router . handle ( request , context ) ;
4956 } catch ( e ) {
5057 // Send to sentry, if it's disabled this will just noop
You can’t perform that action at this time.
0 commit comments