mirror of
https://github.com/overleaf/overleaf.git
synced 2025-01-27 06:33:42 +00:00
Merge pull request #2923 from overleaf/jpa-sentry-in-staging
[misc] sentry: allow reports for resources on the same origin and CDN GitOrigin-RevId: 617939dccef839eb80df0b9d84e6684b5b2e618f
This commit is contained in:
parent
ae327e7fd0
commit
5d9740408a
2 changed files with 4 additions and 3 deletions
|
@ -366,6 +366,8 @@ module.exports = function(webRouter, privateApiRouter, publicApiRouter) {
|
|||
recaptchaDisabled:
|
||||
Settings.recaptcha != null ? Settings.recaptcha.disabled : undefined,
|
||||
validRootDocExtensions: Settings.validRootDocExtensions,
|
||||
sentryAllowedOriginRegex:
|
||||
Settings.sentry && Settings.sentry.allowedOriginRegex,
|
||||
sentryDsn: Settings.sentry != null ? Settings.sentry.publicDSN : undefined
|
||||
}
|
||||
next()
|
||||
|
|
|
@ -7,11 +7,10 @@ if (window.ExposedSettings.sentryDsn) {
|
|||
Sentry.init({
|
||||
dsn: window.ExposedSettings.sentryDsn,
|
||||
|
||||
// Ignore errors unless they come from overleaf.com/sharelatex.com
|
||||
// Ignore errors unless they come from our origins
|
||||
// Adapted from: https://docs.sentry.io/platforms/javascript/#decluttering-sentry
|
||||
whitelistUrls: [
|
||||
/https:\/\/[a-z]+\.overleaf\.com/,
|
||||
/https:\/\/[a-z]+\.sharelatex\.com/
|
||||
new RegExp(window.ExposedSettings.sentryAllowedOriginRegex)
|
||||
],
|
||||
|
||||
ignoreErrors: [
|
||||
|
|
Loading…
Reference in a new issue