Update dotEnv.ts to ignore OTEL_EXPORTER_OTLP_ENDPOINT as well (#1307)

* Update dotEnv.ts

* Create four-buttons-run.md

---------

Co-authored-by: Eric Allam <eallam@icloud.com>
This commit is contained in:
Niels
2024-09-19 16:25:17 +02:00
committed by GitHub
parent c65d4822b4
commit 64862db846
2 changed files with 6 additions and 0 deletions
+5
View File
@@ -0,0 +1,5 @@
---
"trigger.dev": patch
---
Ignore OTEL_EXPORTER_OTLP_ENDPOINT environment variable from `.env` files, to prevent the internal OTEL_EXPORTER_OTLP_ENDPOINT being overwritten with a user-supplied value.
+1
View File
@@ -21,6 +21,7 @@ export function resolveDotEnvVars(cwd?: string, envFile?: string) {
// remove TRIGGER_API_URL and TRIGGER_SECRET_KEY, since those should be coming from the worker
delete result.TRIGGER_API_URL;
delete result.TRIGGER_SECRET_KEY;
delete result.OTEL_EXPORTER_OTLP_ENDPOINT;
return result;
}