chore: Add optional DD tracer
This commit is contained in:
@@ -1,6 +1,12 @@
|
||||
// @flow
|
||||
require("dotenv").config({ silent: true });
|
||||
|
||||
// If the DataDog agent is installed and the DD_API_KEY environment variable is
|
||||
// in the environment then we can safely attempt to start the DD tracer
|
||||
if (process.env.DD_API_KEY) {
|
||||
require("dd-trace").init();
|
||||
}
|
||||
|
||||
if (
|
||||
!process.env.SECRET_KEY ||
|
||||
process.env.SECRET_KEY === "generate_a_new_key"
|
||||
|
||||
Reference in New Issue
Block a user