Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Option to exclude certain ENV variables from auto-instrumentation #3462

Open
dkPranav opened this issue Nov 15, 2024 · 0 comments
Open

Option to exclude certain ENV variables from auto-instrumentation #3462

dkPranav opened this issue Nov 15, 2024 · 0 comments
Labels
enhancement New feature or request needs triage

Comments

@dkPranav
Copy link

Component(s)

auto-instrumentation

Is your feature request related to a problem? Please describe.

We are setting OTEL_SERVICE_NAME in the container image Dockerfile across many deployments.
We don't want the auto-instrumentation to inject this OTEL_SERVICE_NAME, so is there a way exclude injection of certain Env variables.

Describe the solution you'd like

I believe these are the default ENVs injected when instrumentation.opentelemetry.io/inject-sdk annotation is added to a PodSpec,

OTEL_NODE_IP
OTEL_POD_IP
OTEL_SERVICE_NAME 
OTEL_RESOURCE_ATTRIBUTES_POD_NAME
OTEL_RESOURCE_ATTRIBUTES_NODE_NAME
OTEL_RESOURCE_ATTRIBUTES

Is there a way to exclude injection of them using the Intrumentation CR.

Describe alternatives you've considered

I understand that we can explicitly pass these ENVs in the pod directly to override the default values. and also add an annotation to add custom attributes.

Additional context

No response

@dkPranav dkPranav added enhancement New feature or request needs triage labels Nov 15, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request needs triage
Projects
None yet
Development

No branches or pull requests

1 participant