Skip to content

Commit

Permalink
fix(Sentry): up to date configs
Browse files Browse the repository at this point in the history
  • Loading branch information
awinogradov committed May 16, 2023
1 parent b08d90d commit 3d2ec7a
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 0 deletions.
File renamed without changes.
File renamed without changes.
13 changes: 13 additions & 0 deletions sentry.server.config.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
import * as Sentry from '@sentry/nextjs';

const SENTRY_DSN = process.env.SENTRY_DSN || process.env.NEXT_PUBLIC_SENTRY_DSN;

if (SENTRY_DSN) {
if (process.env.NODE_ENV === 'production') {
Sentry.init({
dsn: SENTRY_DSN,
tracesSampleRate: 1.0,
release: process.env.SENTRY_RELEASE,
});
}
}

0 comments on commit 3d2ec7a

Please sign in to comment.