Integration Setup for ECS Fargate

이 페이지는 아직 한국어로 제공되지 않으며 번역 작업 중입니다. 번역에 관한 질문이나 의견이 있으시면 언제든지 저희에게 연락해 주십시오.

Set up integrations for ECS Fargate with Docker Label Annotations.

Add an integration

If you already set up the Container Agent in ECS Fargate, follow these steps to add an integration to your existing cluster.

Update the task definition

  1. Log in to your AWS Web Console and navigate to the ECS section.
  2. Choose the cluster the Datadog Agent is running on.
  3. Click the Tasks tab, then click the Task definition name containing the Datadog Agent Container.
  4. Click the Create new revision button, then click the Add container button.
  5. Enter the Container name, Image, and any additional preference settings.
  6. Under Docker labels add the following:
KeyValue
com.datadoghq.ad.instances[{"host": "%%host%%", "port": <PORT_NUMBER>}]
com.datadoghq.ad.check_names["<CHECK_NAME>"]
com.datadoghq.ad.init_configs[{}]
  1. Click the Add button, then click the Create button.

Update the service

  1. Within the cluster, click the Services tab, then click the Service Name.
  2. Click the Update button.
  3. For the Task Definition, choose the latest Revision from the dropdown menu.
  4. Click the Next step button 3 times, then click the Update Service button.

Verification

When the updated Task displays a RUNNING status, use these pages to verify information is reporting to Datadog:

Examples

Use the following table to enter the Docker labels via the AWS Web Console for a Redis container:

KeyValue
com.datadoghq.ad.instances[{"host": "%%host%%", "port": 6379}]
com.datadoghq.ad.check_names["redisdb"]
com.datadoghq.ad.init_configs[{}]

Use the following JSON under containerDefinitions to create a Redis container via the AWS CLI tools.

{
  "name": "redis",
  "image": "redis:latest",
  "essential": true,
  "dockerLabels": {
    "com.datadoghq.ad.instances": "[{\"host\": \"%%host%%\", \"port\": 6379}]",
    "com.datadoghq.ad.check_names": "[\"redisdb\"]",
    "com.datadoghq.ad.init_configs": "[{}]"
  }
}

Further Reading

PREVIEWING: safchain/fix-custom-agent