Resource: aws_guardduty_organization_admin_account

Manages a GuardDuty Organization Admin Account. The AWS account utilizing this resource must be an Organizations primary account. More information about Organizations support in GuardDuty can be found in the GuardDuty User Guide.

Example Usage

resource "aws_organizations_organization" "example" {
  aws_service_access_principals = ["guardduty.amazonaws.com"]
  feature_set                   = "ALL"
}

resource "aws_guardduty_detector" "example" {}

resource "aws_guardduty_organization_admin_account" "example" {
  depends_on = [aws_organizations_organization.example]

  admin_account_id = "123456789012"
}

Argument Reference

This resource supports the following arguments:

Attribute Reference

This resource exports the following attributes in addition to the arguments above:

Import

In Terraform v1.5.0 and later, use an import block to import GuardDuty Organization Admin Account using the AWS account ID. For example:

import {
  to = aws_guardduty_organization_admin_account.example
  id = "123456789012"
}

Using terraform import, import GuardDuty Organization Admin Account using the AWS account ID. For example:

% terraform import aws_guardduty_organization_admin_account.example 123456789012