This is a playground for OpenTelemetry. It contains a simple ASP.NET Core 8 web application that sends metrics to Prometheus. Grafana is used to visualize the metrics.
- Clone the repository
- Install or upgrade to the latest dotnet 8 SDK preview using: 'winget install Microsoft.DotNet.SDK.Preview'
- Build the api and run it locally
- Publish the api as a docker image
- dotnet build
- dotnet run
- dotnet publish --os linux --arch x64 -p:PublishProfile=DefaultContainer --output .\publish
- docker run --name api -it --rm -p 5010:8080 -e "ASPNETCORE_ENVIRONMENT=Development" opentelemetryplayground-api:latest
- Run
docker-compose up
- Validate that prometheus is running at http://localhost:9090
- Validate that grafana is running at http://localhost:3000
- Login to grafana with
admin
andadmin
- Browse dashboards and open the 'ASP.NET Core' dashboard