Provides a Global Accelerator (GA) Bandwidth Package Attachment resource.
For information about Global Accelerator (GA) Bandwidth Package Attachment and how to use it, see What is Bandwidth Package Attachment.
Basic Usage
resource "alicloud_ga_accelerator" "example" {
duration = 1
auto_use_coupon = true
spec = "1"
}
resource "alicloud_ga_bandwidth_package" "example" {
bandwidth = 20
type = "Basic"
bandwidth_type = "Basic"
duration = 1
auto_pay = true
ratio = 30
}
resource "alicloud_ga_bandwidth_package_attachment" "example" {
accelerator_id = alicloud_ga_accelerator.example.id
bandwidth_package_id = alicloud_ga_bandwidth_package.example.id
}
The following arguments are supported:
accelerator_id
- (Required, ForceNew) The ID of the Global Accelerator instance from which you want to disassociate the bandwidth plan.bandwidth_package_id
- (Required) The ID of the bandwidth plan to disassociate. NOTE: From version 1.192.0, bandwidth_package_id
can be modified.The following attributes are exported:
id
- The resource ID in terraform of Bandwidth Package Attachment. Value as <accelerator_id>:<bandwidth_package_id>
. Before version 1.120.0, the value is <bandwidth_package_id>
.accelerators
- Accelerators bound with current Bandwidth Package.status
- State of Bandwidth Package.The timeouts
block allows you to specify timeouts for certain actions:
create
- (Defaults to 5 mins) Used when create the Bandwidth Package Attachment.update
- (Defaults to 5 mins) Used when update the Bandwidth Package Attachment.delete
- (Defaults to 5 mins) Used when delete the Bandwidth Package Attachment.Ga Bandwidth Package Attachment can be imported using the id. Format to <accelerator_id>:<bandwidth_package_id>
, e.g.
$ terraform import alicloud_ga_bandwidth_package_attachment.example your_accelerator_id:your_bandwidth_package_id