Data Source: aws_organizations_policies_for_target

Terraform data source for managing an AWS Organizations Policies For Target.

Example Usage

Basic Usage

data "aws_organizations_organization" "example" {}

data "aws_organizations_policies_for_target" "example" {
  target_id = data.aws_organizations_organization.example.roots[0].id
  filter    = "SERVICE_CONTROL_POLICY"
}

data "aws_organizations_policy" "example" {
  for_each  = toset(data.aws_organizations_policies_for_target.example.ids)
  policy_id = each.value
}

Argument Reference

The following arguments are required:

Attribute Reference

This data source exports the following attributes in addition to the arguments above: