alicloud_resource_manager_shared_target

更新时间:

Provides a Resource Manager Shared Target resource.

For information about Resource Manager Shared Target and how to use it, see What is Shared Target.

-> NOTE: Available since v1.111.0.

Example Usage

Basic Usage


variable "name" {
  default = "tfexample"
}
data "alicloud_resource_manager_accounts" "default" {}

resource "alicloud_resource_manager_resource_share" "example" {
  resource_share_name = var.name
}

resource "alicloud_resource_manager_shared_target" "example" {
  resource_share_id = alicloud_resource_manager_resource_share.example.id
  target_id         = data.alicloud_resource_manager_accounts.default.ids.0
}

Argument Reference

The following arguments are supported:

  • resource_share_id - (Required, ForceNew) The resource share ID of resource manager.
  • target_id - (Required, ForceNew) The member account ID in resource directory.

Attributes Reference

The following attributes are exported:

  • id - The resource ID of Shared Target. The value is formatted <resource_share_id>:<target_id>.
  • status - The status of shared target.

Timeouts

The timeouts block allows you to specify timeouts for certain actions:

  • create - (Defaults to 11 mins) Used when create the Shared Target.
  • delete - (Defaults to 11 mins) Used when delete the Shared Target.

Import

Resource Manager Shared Target can be imported using the id, e.g.

$ terraform import alicloud_resource_manager_shared_target.example <resource_share_id>:<target_id>