AWS 매뉴얼 설정 가이드

개요

이 가이드를 사용하여 Datadog AWS 통합을 수동으로 설정합니다.

AWS 통합을 수동으로 설정하려면 AWS 계정에서 IAM 정책 및 IAM 역할을 생성하고 Datadog 계정에 생성된 AWS 외부 ID로 역할을 설정합니다. 이를 통해 Datadog의 AWS 계정이 사용자 대신 AWS API를 쿼리하고 데이터를 Datadog 계정으로 가져올 수 있습니다. 아래 섹션에서는 이러한 각 구성 요소를 생성한 후 Datadog 계정에서 설정을 완료하는 단계까지 자세히 설명합니다.

설정

외부 ID 생성

  1. AWS 통합 설정 페이지에서 Add AWS Account를 클릭한 다음 Manually을 선택합니다.
  2. 액세스 유형으로 Role Delegation을 선택하고 AWS External ID을 복사합니다. 외부 ID에 대한 자세한 내용은 IAM 사용자 지침을 참조하세요. 참고: 해당 기간 동안 사용자가 명시적으로 변경하거나 다른 AWS 계정을 Datadog에 추가하지 않는 한, 외부 ID는 48시간 동안 사용 가능하며 재생성되지 않습니다. 이 기간 내에 새 AWS 계정 추가 페이지에서 외부 ID 변경 없이 계정 추가 프로세스를 완료할 수 있습니다.

Datadog의 AWS IAM 정책

Datadog에서 제공하는 모든 AWS 통합을 활용하려면 필수 권한을 사용하여 AWS 계정에 Datadog 역할에 대한 IAM 정책을 생성합니다. 다른 구성 요소가 통합에 추가되면 이러한 권한이 변경될 수 있습니다.

  1. AWS IAM 콘솔에서 새 정책을 생성합니다.
  2. JSON 탭을 선택하고 권한 정책을 텍스트 상자에 붙여 넣습니다. 참고: 옵션으로 IAM 정책에 조건 요소를 추가할 수 있습니다. 예를 들어, 조건을 사용하여 모니터링을 특정 지역으로 제한할 수 있습니다.
  3. Next: TagsNext: Review를 클릭합니다.
  4. 정책 이름을 DatadogIntegrationPolicy 또는 원하는 이름으로 지정하고 적절한 설명을 제공합니다.
  5. Create policy을 클릭합니다.

Datadog에 대한 AWS IAM 역할

Datadog이 IAM 정책에 정의된 권한을 사용할 수 있도록 IAM 역할을 만듭니다.

  1. AWS IAM 콘솔에서 새 역할을 생성합니다.
  2. 신뢰할 수 있는 엔티티 유형에 대해 AWS account을 선택하고 Another AWS account을 선택합니다.

  1. Account ID464622532012를 입력합니다. Datadog의 계정 ID이며, Datadog에게 AWS 데이터에 대한 액세스 권한을 부여합니다.

  1. Account ID417141415827를 입력합니다. Datadog의 계정 ID이며, Datadog에게 AWS 데이터에 대한 액세스 권한을 부여합니다.

  1. 통합하려는 AWS 계정이 GovCloud 계정인 경우 065115117704Account ID로 입력하고, 그렇지 않으면 392588925713을 입력합니다. 이는 Datadog의 계정 ID이며 Datadog에게 AWS 데이터에 대한 액세스 권한을 부여합니다.

  1. Require external ID를 선택하고 외부 ID 생성 섹션에 복사된 외부 ID를 입력합니다. Require MFA를 사용하지 않도록 설정하세요. 자세한 내용은 제3자에게 AWS 리소스 액세스 권한 부여 시 외부 ID를 사용하는 방법 AWS 설명서를 참조하세요.
  2. Next를 클릭합니다.
  3. 정책을 이미 만든 경우 이 페이지에서 정책을 검색하고 선택합니다. 그렇지 않으면 새 창에서 열리는 Create Policy를 클릭하고 이전 섹션의 지침을 따릅니다.
  4. (선택 사항)AWS 보안감사 정책을 역할에 연결하여 Cloud Security Management Misconfiguration을 사용할 수 있습니다.
  5. Next를 클릭합니다.
  6. 적절한 설명과 함께 DatadogIntegrationRole와 같은 이름을 지정합니다.
  7. Create Role을 클릭합니다.

Datadog에서 설정 완료

  1. 다른 탭에서 열었던 계정을 Datadog에 수동으로 추가하려면 AWS 통합 설정 페이지로 돌아갑니다. Datadog IAM 역할이 AWS 계정에 추가되었는지 확인하려면 체크박스를 클릭합니다.
  2. 123456789012와 같이 계정 ID를 대시 없이입력합니다. 계정 ID는 Datadog에 대해 생성된 역할의 ARN에서 확인할 수 있습니다.
  3. 이전 섹션에서 만든 역할의 이름을 입력하고 저장을 클릭합니다. 참고: 통합 타일에 입력하는 역할 이름은 대소문자를 구분하며, AWS의 역할 이름과 정확히 일치해야 합니다.
  4. 만약 Datadog이 sts:AssumeRole 작업을 수행할 권한이 없음 오류가 발생한다면, UI에서 권장하는 문제 해결 단계를 따르거나 문제 해결 가이드를 참조하세요.
  5. 데이터 수집이 시작될 때까지 최대 10분 정도 기다린 후 사용 가능한 AWS 개요 대시보드를 통해 AWS 서비스 및 인프라스트럭처에서 전송된 메트릭을 확인합니다.

설정

AWS

  1. AWS 콘솔에서 필수 권한을 사용하여 Datadog 통합에 사용할 IAM 사용자를 생성합니다.
  2. Datadog 통합 IAM 사용자용 액세스 키와 시크릿 키를 생성하세요.

Datadog

  1. AWS 통합 타일에서 Add AWS Account를 클릭한 다음 Manually을 선택합니다.
  2. Access Keys (GovCloud or China* Only) 탭을 선택합니다.
  3. Datadog 통합의 IAM 사용자가 AWS 계정에 추가되었음을 확인합니다 체크박스를 클릭합니다.
  4. Account ID, AWS Access Key, AWS Secret Key를 입력합니다. GovCloud 및 China에 대한 액세스 및 보안 키만 허용됩니다.
  5. 저장을 클릭합니다.
  6. 데이터 수집이 시작될 때까지 최대 10분 정도 기다린 후 사용 가능한 AWS 개요 대시보드를 통해 AWS 서비스 및 인프라스트럭처에서 전송된 메트릭을 확인합니다.

* 중국 본토에서(또는 내부 환경과 관련된) Datadog 서비스의 모든 사용에는 당사 웹사이트의 Restricted Service Locations 섹션에 게시된 면책 조항이 적용됩니다.

AWS IAM Permissions

AWS IAM permissions enable Datadog to collect metrics, tags, EventBridge events, and other data necessary to monitor your AWS environment.

To correctly set up the AWS Integration, you must attach the relevant IAM policies to the Datadog AWS Integration IAM Role in your AWS account.

AWS Integration IAM Policy

The set of permissions necessary to use all the integrations for individual AWS services.

The following permissions included in the policy document use wild cards such as List* and Get*. If you require strict policies, use the complete action names as listed and reference the Amazon API documentation for your respective services.

{
    "Version": "2012-10-17",
    "Statement": [
        {
            "Action": [
                "apigateway:GET",
                "autoscaling:Describe*",
                "backup:List*",
                "budgets:ViewBudget",
                "cloudfront:GetDistributionConfig",
                "cloudfront:ListDistributions",
                "cloudtrail:DescribeTrails",
                "cloudtrail:GetTrailStatus",
                "cloudtrail:LookupEvents",
                "cloudwatch:Describe*",
                "cloudwatch:Get*",
                "cloudwatch:List*",
                "codedeploy:List*",
                "codedeploy:BatchGet*",
                "directconnect:Describe*",
                "dynamodb:List*",
                "dynamodb:Describe*",
                "ec2:Describe*",
                "ec2:GetTransitGatewayPrefixListReferences",
                "ec2:SearchTransitGatewayRoutes",
                "ecs:Describe*",
                "ecs:List*",
                "elasticache:Describe*",
                "elasticache:List*",
                "elasticfilesystem:DescribeFileSystems",
                "elasticfilesystem:DescribeTags",
                "elasticfilesystem:DescribeAccessPoints",
                "elasticloadbalancing:Describe*",
                "elasticmapreduce:List*",
                "elasticmapreduce:Describe*",
                "es:ListTags",
                "es:ListDomainNames",
                "es:DescribeElasticsearchDomains",
                "events:CreateEventBus",
                "fsx:DescribeFileSystems",
                "fsx:ListTagsForResource",
                "health:DescribeEvents",
                "health:DescribeEventDetails",
                "health:DescribeAffectedEntities",
                "kinesis:List*",
                "kinesis:Describe*",
                "lambda:GetPolicy",
                "lambda:List*",
                "logs:DeleteSubscriptionFilter",
                "logs:DescribeLogGroups",
                "logs:DescribeLogStreams",
                "logs:DescribeSubscriptionFilters",
                "logs:FilterLogEvents",
                "logs:PutSubscriptionFilter",
                "logs:TestMetricFilter",
                "organizations:Describe*",
                "organizations:List*",
                "rds:Describe*",
                "rds:List*",
                "redshift:DescribeClusters",
                "redshift:DescribeLoggingStatus",
                "route53:List*",
                "s3:GetBucketLogging",
                "s3:GetBucketLocation",
                "s3:GetBucketNotification",
                "s3:GetBucketTagging",
                "s3:ListAllMyBuckets",
                "s3:PutBucketNotification",
                "ses:Get*",
                "sns:List*",
                "sns:Publish",
                "sqs:ListQueues",
                "states:ListStateMachines",
                "states:DescribeStateMachine",
                "support:DescribeTrustedAdvisor*",
                "support:RefreshTrustedAdvisorCheck",
                "tag:GetResources",
                "tag:GetTagKeys",
                "tag:GetTagValues",
                "xray:BatchGetTraces",
                "xray:GetTraceSummaries"
            ],
            "Effect": "Allow",
            "Resource": "*"
        }
    ]
}

AWS Security Audit Policy

To use resource collection, attach AWS’s managed SecurityAudit Policy to your Datadog IAM role.