Resource: aws_ami_launch_permission#
Adds a launch permission to an Amazon Machine Image (AMI).
Example Usage#
AWS Account ID#
resource "aws_ami_launch_permission" "example" {
image_id = "cmi-12345678"
account_id = "123456789012"
}
Public Access#
# The cloud currently restricts adding public access permissions to images.
# Applying the resource must throw an error.
resource "aws_ami_launch_permission" "example" {
image_id = "cmi-12345678"
group = "all"
}
Argument Reference#
The following arguments are supported:
image_id
- (Required) The ID of the image.account_id
- (Optional) The ID of the project (project@customer
) for the launch permission.group
- (Optional) The name of the group for the launch permission.- Valid values:
all
- Valid values:
Attribute Reference#
Supported attributes#
In addition to all arguments above, the following attributes are exported:
id
- The ID of the launch permission.
Unsupported attributes#
~> Note These attributes may be present in the terraform.tfstate
file, but they have preset values and cannot be specified in configuration files.
The following attributes are not currently supported:
organization_arn
, organizational_unit_arn
.
Import#
-> Unsupported operation Import image launch permission is currently unsupported.