Skip to content

Commit

Permalink
#35 Use doppler config instead of node env for sentry environment
Browse files Browse the repository at this point in the history
  • Loading branch information
danielemery committed Sep 25, 2023
1 parent 4c086ad commit f9245fb
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 2 additions & 0 deletions src/config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ interface QuizlordConfig {
FILE_ACCESS_BASE_URL: string;
QUIZLORD_VERSION: string;
SENTRY_DSN: string;
DOPPLER_CONFIG: string;
}

const schema = Joi.object<QuizlordConfig>()
Expand All @@ -35,6 +36,7 @@ const schema = Joi.object<QuizlordConfig>()
FILE_ACCESS_BASE_URL: Joi.string().required(),
QUIZLORD_VERSION: Joi.string().default('development'),
SENTRY_DSN: Joi.string().required(),
DOPPLER_CONFIG: Joi.string().required(),
})
.required()
.unknown(true);
Expand Down
2 changes: 1 addition & 1 deletion src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ async function initialise() {
],
tracesSampleRate: 1.0,
profilesSampleRate: 1.0,
environment: config.NODE_ENV,
environment: config.DOPPLER_CONFIG,
});

await server.start();
Expand Down

0 comments on commit f9245fb

Please sign in to comment.