stein korsveien
stein korsveien

Reputation: 1117

How do I Configure AWS Distro for OpenTelemetry to send data to Datadog in Pulumi?

I want to send logs, metrics, and trace data from my Java code that are placed inside the steinko/helloworld-backend docker container to Datadog. I am using AWS Distro for OpenTelemetry container as a side car. To configure the Datadog exporter with a YAML file config.yaml.

I place these two components in an ECS Fargate Service by using Pulumi code:

export const service = new awsx.ecs.FargateService("backend", {
  taskDefinitionArgs: {  
    containers: {  
      otelCollector: {                                                                                                                                                     
        image:"docker.io/amazon/aws-otel-collector"
      },
      backend: { 
        image: 'steinko/helloworld-backend',
                                                                            
      },
      dependsOn: [ {
        containerName: "otelCollector",                                                                       
        condition: "START"
      } ]
    }
  }

How do I configure a config.yaml file to docker.io/amazon/aws-otel-collector in Pulumi code?

Upvotes: 1

Views: 612

Answers (2)

markrin
markrin

Reputation: 17

I did that by creating docker image that COPY needed config file to some path and then sets CMD ["--config=/path/to/config"]

Upvotes: 0

Michael Hausenblas
Michael Hausenblas

Reputation: 14001

ADOT PM here, thanks for raising this topic. In our ECS integration we support configurations for AWS X-Ray (traces) and Amazon Managed Service for Prometheus/Amazon CloudWatch (metrics), that is, your use case is currently not supported out-of-the-box. You would need to explicitly set up the ADOT collector (incl. volume for the config; see the examples as a starting point).

If you'd like to create a feature request for out-of-the-box support, please use our public roadmap. Also, note that ADOT at the moment does not yet support logs.

Upvotes: 0

Related Questions