Datadog Agent for ECS Launch Type=EC2
Overview
On ECS launch type EC2, I set datadog/agent:latest in the task definition, but
there was an issue where metrics could not be collected.
Under Infrastructure > Containers, the container information from the task definition that included datadog/agent:latest was listed, but the metrics were not being collected.
Conclusion
Referring to ttps://docs.datadoghq.com/json/datadog-agent-ecs.json, the following volume mount configuration was required.
1 | datadog: |
It was a painful reminder to read the documentation carefully.

