Skip to main content
Providers

IamPolicy

A resource of the AWS provider, version 0.3.0, in its IAM group. Import it with:

import IamPolicy from "aws/iam"

Example

resource IamPolicy example {
    name        = "example-value"
    description = "example-value"
    path        = "example-value"
    policy      = "example-value"
    tags        = "..."
}

Properties

Set by your code in the resource block. A required one must be set; any other you leave out takes the value under Default, if it has one.

NameTypeDefaultRequiredDescription
namestring—NoName of the policy
descriptionstring—NoDescription of the policy
pathstring—NoPath for the policy (default: /)
policystring—NoThe JSON policy document
tagsobject—NoTags to apply to the policy

Set by AWS after the resource is created: your code can read them but not set them. An importable one identifies an existing resource.

NameTypeImportableDescription
policyIdstringNoThe stable and unique ID for the policy
arnstringYesThe Amazon Resource Name (ARN) of the policy
createDatestringNoThe date and time when the policy was created
attachmentCountnumberNoThe number of entities (users, groups, roles) attached to this policy
defaultVersionIdstringNoThe default version ID of the policy

On this page