File tree Expand file tree Collapse file tree 3 files changed +14
-16
lines changed Expand file tree Collapse file tree 3 files changed +14
-16
lines changed Original file line number Diff line number Diff line change 7
7
},
8
8
"scripts" : {
9
9
"build" : " tsc" ,
10
- "start" : " yarn build && node dist/app.js" ,
10
+ "start" : " yarn build && node --require ./dist/instrumentation.js dist/app.js" ,
11
11
"clean" : " npx rimraf node_modules,pnpm-lock.yaml"
12
12
},
13
13
"license" : " MIT" ,
Original file line number Diff line number Diff line change
1
+ // import './instrumentation'; // file preloaded with --require option in node call
1
2
import * as Sentry from '@sentry/node' ;
2
- import dotenv from 'dotenv' ;
3
-
4
- dotenv . config ( { path : './../../.env' } ) ;
5
-
6
- Sentry . init ( {
7
- environment : 'qa' , // dynamic sampling bias to keep transactions
8
- dsn : process . env . SENTRY_DSN ,
9
- includeLocalVariables : true ,
10
- debug : true ,
11
- tunnel : `http://localhost:3031/` , // proxy server
12
- tracesSampleRate : 1 ,
13
- } ) ;
14
-
15
3
import Hapi from '@hapi/hapi' ;
16
4
17
- dotenv . config ( { path : './../../.env' } ) ;
18
-
19
5
declare global {
20
6
namespace globalThis {
21
7
var transactionIds : string [ ] ;
Original file line number Diff line number Diff line change
1
+ import * as Sentry from '@sentry/node' ;
2
+ import dotenv from 'dotenv' ;
3
+
4
+ dotenv . config ( { path : './../../.env' } ) ;
5
+
6
+ Sentry . init ( {
7
+ environment : 'qa' , // dynamic sampling bias to keep transactions
8
+ dsn : process . env . SENTRY_DSN ,
9
+ includeLocalVariables : true ,
10
+ tunnel : `http://localhost:3031/` , // proxy server
11
+ tracesSampleRate : 1 ,
12
+ } ) ;
You can’t perform that action at this time.
0 commit comments