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

More details - How to get OTEL from custom container resource #2569

Open
maddymontaquila opened this issue Feb 11, 2025 · 0 comments
Open

More details - How to get OTEL from custom container resource #2569

maddymontaquila opened this issue Feb 11, 2025 · 0 comments

Comments

@maddymontaquila
Copy link
Member

maddymontaquila commented Feb 11, 2025

Type of issue

Missing information

Description

I want to get the OTel and log stream from a dotnet project container, and I think I need to use WithOtlpExporter:

var backend = builder.AddContainer("backend", "ghcr.io/maddymontaquila/multirepodemo-backend")
.WithLifetime(ContainerLifetime.Persistent)
.WithOtlpExporter()
.WithHttpEndpoint(targetPort: 8080, name: "endpoint");

The logs flow through, but none of the OTel stuff does, even though the env is set in the container vars:

Image

There seems to be a bug here - dotnet/aspire#4131 but googling this is proving impossible because you can also containerize the dashboard and all the results are for that lol

Page URL

https://learn.microsoft.com/en-us/dotnet/aspire/fundamentals/app-host-overview?tabs=docker

Content source URL

https://github.com/dotnet/docs-aspire/blob/main/docs/fundamentals/app-host-overview.md

Document Version Independent Id

2dc8f42f-e9ca-fbe1-bef9-af4b4f20dc7d

Article author

@IEvangelist

Related Issues

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant