-
Notifications
You must be signed in to change notification settings - Fork 87
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(feature-manager): remove Sentry from feature manager (#2130)
* feat(feature-manager): remove Sentry from feature manager * build(dev): add dev defaults for Sentry config
- Loading branch information
1 parent
e62494e
commit d087588
Showing
7 changed files
with
35 additions
and
46 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -40,8 +40,9 @@ services: | |
- MYINFO_CLIENT_SECRET=mockClientSecret | ||
- WEBHOOK_SQS_URL=http://localhost:4566/000000000000/local-webhooks-sqs-main | ||
- INTRANET_IP_LIST_PATH | ||
- SENTRY_CONFIG_URL=https://[email protected]/123456 | ||
- CSP_REPORT_URI=https://[email protected]/123456 | ||
- GA_TRACKING_ID | ||
- SENTRY_CONFIG_URL | ||
- TWILIO_ACCOUNT_SID | ||
- TWILIO_API_KEY | ||
- TWILIO_API_SECRET | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,21 +1,28 @@ | ||
import { FeatureNames, RegisterableFeature } from './types' | ||
import convict, { Schema } from 'convict' | ||
import { url } from 'convict-format-with-validator' | ||
|
||
const sentryFeature: RegisterableFeature<FeatureNames.Sentry> = { | ||
name: FeatureNames.Sentry, | ||
schema: { | ||
sentryConfigUrl: { | ||
doc: 'Sentry.io URL for configuring the Sentry SDK', | ||
format: 'url', | ||
default: null, | ||
env: 'SENTRY_CONFIG_URL', | ||
}, | ||
cspReportUri: { | ||
doc: 'Endpoint for content security policy reporting', | ||
format: 'url', | ||
default: null, | ||
env: 'CSP_REPORT_URI', | ||
}, | ||
export interface ISentry { | ||
sentryConfigUrl: string | ||
cspReportUri: string | ||
} | ||
|
||
convict.addFormat(url) | ||
|
||
const sentryFeature: Schema<ISentry> = { | ||
sentryConfigUrl: { | ||
doc: 'Sentry.io URL for configuring the Sentry SDK', | ||
format: 'url', | ||
default: null, | ||
env: 'SENTRY_CONFIG_URL', | ||
}, | ||
cspReportUri: { | ||
doc: 'Endpoint for content security policy reporting', | ||
format: 'url', | ||
default: null, | ||
env: 'CSP_REPORT_URI', | ||
}, | ||
} | ||
|
||
export default sentryFeature | ||
export const sentryConfig = convict(sentryFeature) | ||
.validate({ allowed: 'strict' }) | ||
.getProperties() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters