Skip to content

armgit / E2B

Public Imported from GitHub
0

Open-source, secure environment with real-world tools for enterprise-grade agents.

Disable Sentry for `npm start`

Tomas Valenta0183354a60e9
diff --git a/next.config.js b/next.config.js
index 9ff49a0c2..424b6fdaa 100644
--- a/next.config.js
+++ b/next.config.js
@@ -41,35 +41,37 @@ module.exports = nextConfig
const { withSentryConfig } = require('@sentry/nextjs')
-module.exports = withSentryConfig(
- module.exports,
- {
- // For all available options, see:
- // https://github.com/getsentry/sentry-webpack-plugin#options
+module.exports = process.env.BUILD === 'docker'
+ ? module.exports
+ : withSentryConfig(
+ module.exports,
+ {
+ // For all available options, see:
+ // https://github.com/getsentry/sentry-webpack-plugin#options
- // Suppresses source map uploading logs during build
- silent: true,
+ // Suppresses source map uploading logs during build
+ silent: true,
- org: 'devbook-7f',
- project: 'agent-dashboard',
- },
- {
- // For all available options, see:
- // https://docs.sentry.io/platforms/javascript/guides/nextjs/manual-setup/
+ org: 'devbook-7f',
+ project: 'agent-dashboard',
+ },
+ {
+ // For all available options, see:
+ // https://docs.sentry.io/platforms/javascript/guides/nextjs/manual-setup/
- // Upload a larger set of source maps for prettier stack traces (increases build time)
- widenClientFileUpload: true,
+ // Upload a larger set of source maps for prettier stack traces (increases build time)
+ widenClientFileUpload: true,
- // Transpiles SDK to be compatible with IE11 (increases bundle size)
- transpileClientSDK: true,
+ // Transpiles SDK to be compatible with IE11 (increases bundle size)
+ transpileClientSDK: true,
- // Routes browser requests to Sentry through a Next.js rewrite to circumvent ad-blockers (increases server load)
- tunnelRoute: '/monitoring',
+ // Routes browser requests to Sentry through a Next.js rewrite to circumvent ad-blockers (increases server load)
+ tunnelRoute: '/monitoring',
- // Hides source maps from generated client bundles
- hideSourceMaps: true,
+ // Hides source maps from generated client bundles
+ hideSourceMaps: true,
- // Automatically tree-shake Sentry logger statements to reduce bundle size
- disableLogger: true,
- }
-)
+ // Automatically tree-shake Sentry logger statements to reduce bundle size
+ disableLogger: true,
+ }
+ )