We are migrating from ECS to Fargate. In ECS, we could set the hostname in the task definition like this:
\"hostname\": \"%HOST_NAME%\"
It fails to create with the e
I recently experienced this same problem however we took a different path than setting the hostname for each task.
There is an outstanding GitHub issue against the datadog-agent that applies when it is run in a sidecar container on ECS and Fargate: https://github.com/DataDog/datadog-agent/issues/3159
This lead to the discovery of the DD_DOGSTATSD_TAG_CARDINALITY=orchestrator
setting which automatically adds a task_arn tag when running on ECS and Fargate. https://docs.datadoghq.com/getting_started/tagging/assigning_tags/?tab=containerizedenvironments#environment-variables