Conversation
Contributor
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
There was a problem hiding this comment.
Pull request overview
Adds support for configuring OTLP exporter headers (intended for authenticated backends like Grafana Cloud) via environment variables in the API app’s typed env layer and example env file.
Changes:
- Add
OTEL_EXPORTER_OTLP_HEADERSto the API env schema. - Document
OTEL_EXPORTER_OTLP_HEADERSusage inapps/api/.env.example.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 3 comments.
| File | Description |
|---|---|
| apps/api/src/env.ts | Introduces OTEL_EXPORTER_OTLP_HEADERS as an optional env var in the Zod schema. |
| apps/api/.env.example | Adds commented guidance for configuring OTLP headers for authenticated OTLP backends. |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
| OTEL_SERVICE_NAME: z.string().default("events.compsoc.api"), | ||
| OTEL_SERVICE_VERSION: z.string().default("development"), | ||
| OTEL_EXPORTER_OTLP_ENDPOINT: z.string().url().default("http://127.0.0.1:4318"), | ||
| OTEL_EXPORTER_OTLP_HEADERS: z.string().min(1).optional(), |
| OTEL_SERVICE_NAME: z.string().default("events.compsoc.api"), | ||
| OTEL_SERVICE_VERSION: z.string().default("development"), | ||
| OTEL_EXPORTER_OTLP_ENDPOINT: z.string().url().default("http://127.0.0.1:4318"), | ||
| OTEL_EXPORTER_OTLP_HEADERS: z.string().min(1).optional(), |
| OTEL_SERVICE_VERSION=development | ||
| OTEL_EXPORTER_OTLP_ENDPOINT=http://127.0.0.1:4318 | ||
| # Required only when exporting directly to an authenticated OTLP backend such as Grafana Cloud. | ||
| # OTEL_EXPORTER_OTLP_HEADERS="Authorization=Basic%20PLACE" |
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.