Resource: aws_accessanalyzer_analyzer

Manages an Access Analyzer Analyzer. More information can be found in the Access Analyzer User Guide.

Example Usage

Account Analyzer

resource "aws_accessanalyzer_analyzer" "example" {
  analyzer_name = "example"
}

Organization Analyzer

resource "aws_organizations_organization" "example" {
  aws_service_access_principals = ["access-analyzer.amazonaws.com"]
}

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

  analyzer_name = "example"
  type          = "ORGANIZATION"
}

Argument Reference

The following arguments are required:

The following arguments are optional:

configuration Argument Reference

unused_access Argument Reference

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 Access Analyzer Analyzers using the analyzer_name. For example:

import {
  to = aws_accessanalyzer_analyzer.example
  id = "example"
}

Using terraform import, import Access Analyzer Analyzers using the analyzer_name. For example:

% terraform import aws_accessanalyzer_analyzer.example example